Hi Iris,
Thank you so much for your valuable feedback. I wonder why your code gives
you 1512 rows, given that the original structure has 12 columns and 126
rows, so I would expect (125*12)+ 9=1,509 total rows.
Cheers,
Paul
El El vie, 27 de oct. de 2023 a la(s) 10:40 p. m., Iris Simmons <
ikwsi...
You are not getting the structure you want because the indexes are
wrong. They should be something more like this:
i <- 0
for (row in 1:nrow(alajuela_df)){
for (col in 1:ncol(alajuela_df)){
i <- i + 1
df[i,1]=alajuela_df[row,col]
}
}
but I think what you are doing can be written much
Dear friends,
I have the following dataframe:
dim(alajuela_df)
[1] 126 12
dput(alajuela_df)
structure(list(...1 = c(92.9925354, 76.0024254, 44.99547465,
28.00536465, 120.0068103, 31.9980405, 85.0071837, 40.1532933,
19.3120917, 113.12581575, 28.45843425, 114.400074, 143.925,
46.439634, 20.784
Dear Bert,
Thank you very much for your quick reply.
I have tested this, and it indeed appears to be the source of the discrepancy I
observed.
My apologies for overlooking this in the documentation and thank you for
clarifying.
Cheers,
Jan
From: Bert Gunter
Se
Às 19:23 de 26/10/2023, varin sacha via R-help escreveu:
Dear R-Experts,
Here below my R code working but I don't know how to complete/finish my R code
to get the final plot with the extrapolation for the10 more years.
Indeed, I try to extrapolate my data with a linear fit over the next 10 yea
5 matches
Mail list logo