Dear all,
I have weekly data by city (variable citycode). I would like to take the
average of the previous two, three, four weeks (without the current week)
of the variable called value.
This is what I have tried to compute the average of the two previous weeks;
df = df %>%
mutate(value.lag1 =
There is no `value` column in the `dput` output shown in the
question so using `tmin` instead note that the `width=` argument
of `rollapply` can be a list containing a vector of offsets (-1 is prior
value, -2 is value before that, etc.) and that we can use `rollapplyr`
with an `r` on the end to ge
Hi all,
I'm using the medical risk package to determine the risk stratification Index
based on the ICD9 codes. Although, I have been successful in using it, I'm
unable to interpret the output.
here is the sample code
# Calculate RSI for each patient ("id") in dataframe
cases <- data.f
> On Mar 25, 2018, at 7:53 AM, Ramesh YAPALPARVI
> wrote:
>
> Hi all,
>
>
>
> I'm using the medical risk package to determine the risk stratification Index
> based on the ICD9 codes. Although, I have been successful in using it, I'm
> unable to interpret the output.
>
>
>
> here is the
A quick question - is there a limit to the number of levels one can go down
when setting the directory in R studio?
I ask because I have been trying to set the directory to a folder 8 levels down
which R studio won't allow, and when I try to set the directory through
Session/Set Working Director
I am sure that this sort of thing has been asked and answered before,
so in case my suggestions don't work for you, just search the archives
a bit more.
I am also sure that it can be handled directly by numerous functions
in numerous packages, e.g. via time series methods or by calculating
running
This is the wrong place to ask what RStudio can or cannot do. However, if your
question is about R you should try invoking your reproducible example in RGui
or the command line R.exe before posting here.
R has no directory depth limit. There is an operating system limit on returning
paths more
7 matches
Mail list logo