Displaying 3 results from an estimated 3 matches for "depth_".
Did you mean:
depth
2012 Jan 18
3
manipulating data of several columns simultaneously
...alues. But I should reorganize the values
(because I created this as an output before and I want to compare it with an
other dataset). I want that the value on row 2 becomes the value of row 1,
value 3 value 2 and so on. The first value would be NA.
If I would do this for 1 column (with the name depth_1), I would do it like
this:
for (t in 2:60)
{
results$depth[t]<-new$depth_1[t-1]
}
# But in my dataset I have 91 columns and I would like to find a way not
having to write this for every column?
# I cannot give my dataset where I?m working on so I created one just for
trying it out and to pro...
2012 Jan 17
2
result numeric(0) when using variable1[which(variable2="max(variable2)"]
...my variables.
I calculated the Rsquared for different columns and made a list to gather
them. I unlisted this list to create a vector with this values. I want to
know for which column I have the max value of Rsquared.
The columns were always named in the same way. They always start with
results4$depth_ following by the number. The numbers are constructed as:
seq(1,10,0.1). But if the R squared values are now in 1 column, I don?t know
for which column they are calculated. So I made a new data frame with both
columns:
R2 <- unlist(LIST)
Cvalue <- c(seq(1,10,0.1))
results5 <- data.frame(C...
2012 Jan 11
3
Accomplishing a loop on multiple columns
Hello,
I have a question concerning ?for loops? on multiple columns.
I made 91 columns with results (all made together with a for loop) and I
want to us lm to fit the model.
I want to compare the results of all these calculated columns (91) with one
column with observed values. I use the function lm to fit the model and
calculate r.squared. I manage to do this for each column separately:
For