You need to grasp two concepts:
1) Models in R conventionally have predict methods. To plot your model, predict
the dependent variable based on the model object and a grid of your independent
variable(s). Whether you have interactions or logistic regression shouldn't be
relevant to getting a pl
Dear Members,I am having trouble in plotting a 3D ROC curve based on
multinomial logistic regression. I am also interested in finding AUC/Volume
under the surface based on final multivariate model. I do have an interaction
term in my final model.
I tried using "HUM" library. But I failed to fig
You will learn something useful if you search for "rolling join". The zoo
package can handle this, as can the data.table package (read the vignette).
Your decision to pad with NA at the end was ill-considered... the first point
of your first series is between the first two points of your second
There is some discussion of approaches to this here:
https://stackoverflow.com/questions/34096162/dplyr-mutate-replace-on-a-subset-of-rows/34096575#34096575
On Mon, Dec 17, 2018 at 10:30 AM Paul Miller via R-help
wrote:
>
> Hello All,
>
> Season's greetings!
>
> Am trying to replicate some SAS
Specialized: Probably need to email the maintainer. See ?maintainer
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along and
sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Mon, Dec 17, 2018 at 9:27 AM
Thanks for getting me pointed in the right direction. If I happen upon
a satisfactory solution, I will report back!
Nate Parsons
Pronouns: He, Him, His
Graduate Teaching Assistant
Department of Sociology
Portland State University
Portland, Oregon
Schedule an appointment: https://calendly.com/nate
Hi Subhamitra,
As for the error that you mention, it was probably:
Error in axis(1, at = year_mids, labels = 3 - 1 - 1994:3 - 8 - 2017) :
'at' and 'labels' lengths differ, 24 != 1992
Anything more than a passing glance reveals that you didn't read the
explanation I sent about the arguments pass
I got another 10% savings with this example by using only one
subscripting adjustment.
I also fixed a typo in my previous posting (which didn't affect the timing).
microbenchmark(
rmh={
d3 <-data.frame(ID=rownames(d1),
d1,
test1=0,
test2=0,
Thanks very much, Simon!
On 12/17/18, 8:23 AM, "Simon Wood" wrote:
I would quote the p-value, but not the statistic (as it is not a
standard F stat). The actual statistic is given here:
https://urldefense.proofpoint.com/v2/url?u=https-3A__academic.oup.com_biomet_article-2Dpdf
There are some problems with your example. Your code does not produce anything
like your example data frame because you draw only 9 values without
replacement. Your code produces 10 columns, each with the same permutation of
the values 1:9.
Then your desired output does not make sense in terms
this can be dome even faster, and I think more easily read, using only base R
d1 <- data.frame(workshop=rep(1:2,4),
gender=rep(c("f","m"),each=4))
## needed by vector and rowbased, not needed by rmh
library(tibble)
library(plyr)
library(magrittr)
microbenchmark(
vector = {d1 %>
I have a data frame each with 10 variables of integer data for various
attributes about each row of data, and I need to know the highest 5
variables related to each of
row in this data frame and output that to a new data frame. In addition to
the 5 highest variable names, I also need to kn
Dear All,
I apologize if you have already seen in Stack Overflow. I
have not got any response from there so I am posting for help here.
I have data on 1318 time series. Many of these series are of unequal
length. Apart from this also quite a few time points for each of the
series are o
Dear Paul,
R's power is that is works vectorised. Unlike SAS which is rowbased. Using
R in a SAS way will lead to very slow code.
Your examples can be written vectorised
d1 %>%
rownames_to_column("ID") %>%
mutate(
test1 = ifelse(gender == "f" & workshop == 1, 7, 0),
test2 = ifelse(ge
I would quote the p-value, but not the statistic (as it is not a
standard F stat). The actual statistic is given here:
https://academic.oup.com/biomet/article-pdf/100/4/1005/566200/ast038.pdf
On 14/12/2018 04:33, Smith, Desmond wrote:
Dear All,
I have a mgcv::gam model of the form:
m1 <- gam
On 17/12/2018 9:41 AM, pe...@mybetterlife.co.uk wrote:
Hi,
I have recently downloaded R and accessed. I am using Zorro (a development
platform for ForeX) and requested to add my path for RTerm.exe
I can't find RTerm.exe and confirm that I appear to load R using "C:\Program
Files\R\R
Hello All,
Season's greetings!
Am trying to replicate some SAS code in R. The SAS code uses if-then-do code
blocks. I've been trying to do likewise in R as that seems to be the most
reliable way to get the same result.
Below is some toy data and some code that does work. There are some thing
Hi,
I have recently downloaded R and accessed. I am using Zorro (a development
platform for ForeX) and requested to add my path for RTerm.exe
I can't find RTerm.exe and confirm that I appear to load R using "C:\Program
Files\R\R-3.5.1\bin\x64\Rgui.exe"
Regards
Peter H. Willi
Hi
You should add limits and maybe some rotation to x axis
ggplot(df, aes(x, colour = g)) + stat_ecdf() +
scale_x_log10(breaks=breaks, limits=c(0.01, 100))+
theme(axis.text.x = element_text(size=8, angle=45))
Cheers
Petr
> -Original Message-
> From: R-help On Behalf Of Bogdan Tanasa
>
Dear all,
please could you advise me on the following : I would like to display a few
CDF data (the R code is below), by using a set of numerical BREAKS on a X
axis to be shown at EQUAL DISTANCE from each other (although numerically,
the BREAKS are on log10 axis and do not reflecting an equal dist
20 matches
Mail list logo