[R] how to do an external validation with R

2013-05-18 Thread beginner
I would like to do external validation using R software. So far I have used packages like "Design" and "DAAG". However they perform internal validation rather than external one. In order to perform external validation I would have to split my data beforehand into training and test set, leave the te

Re: [R] inverse for formula transformations on LHS

2013-05-18 Thread Stephen Milborrow
Paul Johnson wrote: m1 <- lm(log(y) ~ log(x), data = dat) termplot shows log(y) on the vertical. What if I want y on the vertical? plotmo in the plotmo package has an inverse.func argument, so something like the following might work for you? library(MASS) library(plotmo) log.brain <- log(An

Re: [R] glmer.nb: function not in downloaded lme4 package?

2013-05-18 Thread Ben Bolker
Ross Marriott fish.wa.gov.au> writes: > > Dear R Help, > > I would like to use the glmer.nb function for mixed modelling using negative binomial distribution please. > > On the CRAN website apparently this function is > called from the lme4 package (version 0.9911-1). > > I have download

[R] exporting data into STATA

2013-05-18 Thread Niklas Fischer
Dear All, I am not very familiar with ASCII file format, and now I am trying to export R data frame into STATA When I run write.dta command, there is a warning below appear. 5: In abbreviate(ll, 80L) : abbreviate used with non-ASCII chars Do you have any suggestion to fix it? All the bests

Re: [R] exporting data into STATA

2013-05-18 Thread Prof Brian Ripley
On 18/05/2013 14:05, Niklas Fischer wrote: Dear All, I am not very familiar with ASCII file format, and now I am trying to ASCII is an encoding, not a file format. export R data frame into STATA When I run write.dta command, there is a warning below appear. 5: In abbreviate(ll, 80L) : abbre

[R] [R-pkgs] Probabilistic neural network (PNN)

2013-05-18 Thread Pierre-Olivier Chasset
Dear useRs, I am pleased to announce the release of the new package PNN. PNN implements the algorithm proposed by Specht (1990). It is written in the R statistical language. It solves a common problem in automatic learning. Knowing a set of observations described by a vector of quantitative var

Re: [R] exporting data into STATA

2013-05-18 Thread John Kane
Presumably it means what it says : You have a non-ASCII character in the dataset. Any accented character, for example, is going to be outside the basic ASCII character set. Examples mydata <- data.frame(étt=1:10) # error newdata <- data.frame(ntt=1:10) # no error See http://www.theascii

Re: [R] formatting column names of data frame

2013-05-18 Thread John Kane
As Rainer Schuermann says, use the xtable package. Have a look at the documentation entitled xtable gallary --available at your friendly neigbourhood CRAN site and have a look at section 3.1. and it's probably a good idea to look at ?print.xtable as well You might also what to have a look at th

[R] distances between entities

2013-05-18 Thread Rory Wilson
Hello all, please forgive my lack of knowledge, but I am somewhat new to R and would be very grateful for some help. I have tried some searches, but am not even quite sure what to search for.  I will describe my problem: I have a number of nodes (or entities)  and pairwise (Euclidean) distances f

Re: [R] how to do an external validation with R

2013-05-18 Thread Frank Harrell
Splitting one dataset into training and test is still internal validation, and it requires an enormous sample size (around 20,000 typically) in order to be competitive with the bootstrap. Note that the Design package has been replaced with rms, and rms has two functions for external validation (va

Re: [R] Bivariate - multivariate linear regression

2013-05-18 Thread Michael Friendly
On 5/17/2013 3:45 PM, Jesse Gervais wrote: Hi there, I want to do several bivariate linear regressions and, than, do a multivariate linear regression including only variables significantly associated *(p < 0.15)* with y in bivariate analysis, without having to look manually to those p values.

Re: [R] distances between entities

2013-05-18 Thread William Dunlap
Have you looked into "multidimensional scaling"? There are lots of variants, many of which are in R packages. Bill Dunlap Spotfire, TIBCO Software wdunlap tibco.com > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On > Behalf > Of Rory Wil

[R] arima prediction

2013-05-18 Thread Preetam Pal
Hi all, I have a time series Y which I have modelled as ARIMA(2,0,2) by using the arima function . I want to know the model predicted values so that I can compare them with the actual values. Which function do I need to use to get the predicted values? I have tried to find out, but with no luck ti

Re: [R] arima prediction

2013-05-18 Thread Rui Barradas
Hello, At an R prompt type ?predict.Arima Hope this helps, Rui Barradas Em 18-05-2013 21:42, Preetam Pal escreveu: Hi all, I have a time series Y which I have modelled as ARIMA(2,0,2) by using the arima function . I want to know the model predicted values so that I can compare them with the

Re: [R] peering inside functions in a package?

2013-05-18 Thread Uwe Ligges
On 17.05.2013 12:57, Duncan Murdoch wrote: On 13-05-16 9:56 PM, Seth Myers wrote: Let's say I would like to look inside the function corBrownian in library (ape). When I type in the function name I get the following, which is not nearly the detail that goes into this function. I am wondering

Re: [R] Log scales

2013-05-18 Thread Uwe Ligges
On 17.05.2013 13:34, Emily Gleeson wrote: Dear All, I have a query about using log scales for filled.contour plots. I have used log values on the x and y axes but labelled the axes with their linear (non-log) values. I's like to do the same with the contour values. I want the range to go from

[R] bar plot with non-zero starting level

2013-05-18 Thread Xianwen Chen
Hi, I want to plot grouped bars to compare 95% confidence interval estimates from two models. Each bar represents a 95% confidence interval estimate of a coefficient from one of the two models. Each group represents confidence interval estimates of the same coefficient from the two models. I

Re: [R] arima prediction

2013-05-18 Thread Preetam Pal
Hi, Thanks Rui, but the problem is at this point, I don't want to predict. I want to see for the time being, how good my model fits the previous data points. So, if I specify n.ahead=-1 (or any -ve value) , R shows an error like: Error in rep(1, n.ahead) : invalid 'times' argument How do I get thi

Re: [R] arima prediction

2013-05-18 Thread Berend Hasselman
On 19-05-2013, at 05:25, Preetam Pal wrote: > Hi, > > Thanks Rui, but the problem is at this point, I don't want to predict. > I want to see for the time being, how good my model fits the previous data > points. > So, if I specify n.ahead=-1 (or any -ve value) , R shows an error like: > Error i