Hi all,
I have a large time series data set in this form:
id name year price1 ratio1 price2 ratio2 priceN ratioN
1 A 1888 0.5 0.5 . . 0.7 0.7
1 A 1889 0.1 . 0.2 0.3 . .
2 B 1888 . 0.8 . . 0.9 0.8
2 B 1889 . . 0.4 . 0.5 0.5
with N=2200.
Since there are a lot of missing values and I am almost at the column limit, I want to shift those expressions that are missing to the end and indent those expressions that are at the end. It would be best if the values were sorted in descending order along the variables price or ratio, so that
id name year price1 ratio1 price2 ratio2 priceN ratioN
1 A 1888 0.7 0.7 0.5 0.5 . .
1 A 1889 0.2 0.3 0.1 . . .
2 B 1888 0.9 0.8 . 0.8 . .
2 B 1889 0.5 0.5 0.4 . . .
Any idea how I should proceed?
I would be very grateful for any help, tips and tricks.
Kind regards,
Angelica
I have a large time series data set in this form:
id name year price1 ratio1 price2 ratio2 priceN ratioN
1 A 1888 0.5 0.5 . . 0.7 0.7
1 A 1889 0.1 . 0.2 0.3 . .
2 B 1888 . 0.8 . . 0.9 0.8
2 B 1889 . . 0.4 . 0.5 0.5
with N=2200.
Since there are a lot of missing values and I am almost at the column limit, I want to shift those expressions that are missing to the end and indent those expressions that are at the end. It would be best if the values were sorted in descending order along the variables price or ratio, so that
id name year price1 ratio1 price2 ratio2 priceN ratioN
1 A 1888 0.7 0.7 0.5 0.5 . .
1 A 1889 0.2 0.3 0.1 . . .
2 B 1888 0.9 0.8 . 0.8 . .
2 B 1889 0.5 0.5 0.4 . . .
Any idea how I should proceed?
I would be very grateful for any help, tips and tricks.
Kind regards,
Angelica

Comment