ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   get data in sequence (https://www.excelbanter.com/excel-programming/278692-get-data-sequence.html)

Sam

get data in sequence
 
in column A , i have dates
in column B , i have ibm stock value
in column C , i have nasdaq index values

now , when return from nasdaq was 0 , only for those months i want
to be able to see both the ibm values and nasdaq values with the
dates.

my prob is :

if data starts from jan 03 and in mar 03 and april 03 , nasdaq was -6
, -4 and ibm was 3 and 6 ...

i want to be to see
in column d , dates from jan , feb , may , june , july etc ( no mar
and april pls )
in column e , corr values of ibm
in column f , corr values of nasdaq

this can be done using if statement ....but i want to do it using a
macro..

the other prob is that my data length is not constant, it changes and
my stocks and indices change.....so i may have 1000 rows tomorrow and
only 50 rows the next day ...

how do i get this ?

keepITcool

get data in sequence
 
Have you tried it with a Pivot table?

To enable the Pivot to work with a "variable" data range:

Via insert/define names:
Make this a socalled "dynamic" range, using a formula like
myRange= offset(data!$a$1,0,0,counta(data!$a:$a),counta(dat a!$1:$1))

Via data/Pivottable
Create a pivottable based on that name.
(Press F3 when prompted to enter the range and select the name.)


keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


(Sam) wrote:

in column A , i have dates
in column B , i have ibm stock value
in column C , i have nasdaq index values

now , when return from nasdaq was 0 , only for those months i want
to be able to see both the ibm values and nasdaq values with the
dates.

my prob is :

if data starts from jan 03 and in mar 03 and april 03 , nasdaq was -6
, -4 and ibm was 3 and 6 ...

i want to be to see
in column d , dates from jan , feb , may , june , july etc ( no mar
and april pls )
in column e , corr values of ibm
in column f , corr values of nasdaq

this can be done using if statement ....but i want to do it using a
macro..

the other prob is that my data length is not constant, it changes and
my stocks and indices change.....so i may have 1000 rows tomorrow and
only 50 rows the next day ...

how do i get this ?




All times are GMT +1. The time now is 08:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com