Displaying 5 results from an estimated 5 matches for "myday".
Did you mean:
mydat
2012 Jan 31
4
problem in fitting model in NLS function
...nse_variable = (c/r)*log(1+exp(r*(Day-tt))), where "Day" is time-variable
my response variable
rl <- c(2,1.5,1.8,2,2,2.5,2.6,1.5,2.4,1.7,2.3,2.4,2.2,2.6,
2.8,2,2.5,1.8,2.4,2.4,2.3,2.6,3,2,2.6,1.8,2.5,2.5,
2.3,2.7,3,2.2,2.6,1.8,2.5,2.5,2.3,2.7,3,2.2)
myday <- rep(c(3,5,7,9,10), each = 8) # creating my predictor time-variable
mydata <- data.frame(rl,myday) # data object
# fitting model equation in "nls" function, when i assigned initial value for tt = 0.6,
CASE-I:
> mytest <- nls(rl ~ (c/r)*log(1+exp(r*(myday-tt))), data = my...
2012 Jan 30
1
Problem in Fitting model equation in "nls" function
...ariable = (c/r)*log(1+exp(r*(Day-tt))), where "Day" is time-variable
## my response variable
rl <- c(2,1.5,1.8,2,2,2.5,2.6,1.5,2.4,1.7,2.3,2.4,2.2,2.6,
2.8,2,2.5,1.8,2.4,2.4,2.3,2.6,3,2,2.6,1.8,2.5,2.5,
2.3,2.7,3,2.2,2.6,1.8,2.5,2.5,2.3,2.7,3,2.2)
myday <- rep(c(3,5,7,9,10), each = 8) # creating my predictor time-variable
mydata <- data.frame(rl,myday) # data object
### fitting model equation in "nls" function
### when i assigned initial value for tt = 0.6,
CASE-I:
> mytest <- nls(rl ~ (c/r)*log(1+exp(r*(myday-tt))), da...
2024 Dec 11
2
aggregate produces results in unexpected format
I am trying to use the aggregate function to run a function, catsbydat2, that produces the mean, minimum, maximum, and number of observations of the values in a dataframe, inJan2Test, by levels of the dataframe variable MyDay. The output should be in the form of a dataframe.
#my code:
# This function should process a data frame and return a data frame
# containing the mean, minimum, maximum, and number of observations
# in the data frame for each level of MyDay.
catsbyday2 <- function(df){
# Create a matrix to hol...
2010 Oct 04
2
Generating weekdays only
Dear all, can anyone please tell me how to generate a sequence of days continuously, however without considering weekends i.e. Saturday and Sunday? I am aware of following code:
> seq(as.Date("2010-01-01"), as.Date("2010-02-01"), by="1 day")
[1] "2010-01-01" "2010-01-02" "2010-01-03" "2010-01-04" "2010-01-05"
2011 Nov 08
3
lapply to list of variables
Hi
Can someone help me with this?
How can I apply a function to a list of variables.
something like this
listvar=list("Monday","Tuesday","Wednesday")
func=function(x){x[which(x<=10)]=NA}
lapply(listvar, func)
were
Monday=[213,56,345,33,34,678,444]
Tuesday=[213,56,345,33,34,678,444]
...
in my case I have a neverending list of vectors.
Thanks!