[R] Conditionally remove rows with logic

2016-08-07 Thread Jennifer Sheng
Dear all,

I need to remove any rows AFTER the label becomes 1.  For example, for ID
1, the two rows with TIME of 15 & 18 should be removed; for ID 2, any rows
after time 6, i.e., rows of time 9-18, should be removed.  Any
suggestions?  Thank you very much!

The current dataset looks like the following:
ID TIME LABEL
100
130
160
190
112  1
115  0
118   0
200
230
261
290
212  0
215  0
218  0

Thanks a lot!
Jennifer

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] Creating Dummy Var in R for regression?

2016-08-07 Thread Fredrik Karlsson
Hi,

please also have a look at the 'cut' function.Very handa function for these
types of situations.

Best,

Fredrik

On Sun, Aug 7, 2016 at 8:10 PM, Shivi Bhatia  wrote:

> Thank you Jeremiah and all others for the assistance. This really helped.
>
> On Sat, Aug 6, 2016 at 5:01 AM, jeremiah rounds 
> wrote:
>
> > Something like:
> >
> > d  =  data.frame(score = sample(1:10, 100, replace=TRUE))
> > d$score_t = "low"
> > d$score_t[d$score > 3] = "medium"
> > d$score_t[d$score >7 ] = "high"
> > d$score_t = factor(d$score_t, levels = c("low", "medium", "high"),
> > ordered=TRUE)  #set ordered = FALSE for dummy variables
> > X = model.matrix(~score_t, data=d)
> > X
> >
> >
> >
> > On Fri, Aug 5, 2016 at 3:23 PM, Shivi Bhatia 
> wrote:
> >
> >> Thanks you all for the assistance. This really helps.
> >>
> >> Hi Bert: While searching nabble i got to know R with factors variables
> >> there is no need to create dummy variable. However please consider this
> >> situation:
> >> I am in the process of building a logistic regression model on NPS data.
> >> The outcome variable is CE i.e. customer experience which has 3 rating
> so
> >> ordinal logistic regression will be used. However most of my variables
> are
> >> categorical. For instance one of the variable is agent knowledge which
> is
> >> a
> >> 10 point scale.
> >>
> >> This agent knowledge is again a 3 rated scale: high medium low hence i
> >> need
> >> to group these 10 values into 3 groups & then as you suggested i can
> >> directly enter them in the model without creating n-1 categories.
> >>
> >> I have worked on SAS extensively hence found this a bit confusing.
> >>
> >> Thanks for the help.
> >>
> >> On Sat, Aug 6, 2016 at 2:30 AM, Bert Gunter 
> >> wrote:
> >>
> >> > Just commenting on the email subject, not the content (which you have
> >> > already been helped with): there is no need to *ever* create a dummy
> >> > variable for regression in R if what you mean by this is what is
> >> > conventionally meant. R will create the model matrix with appropriate
> >> > "dummy variables" for factors as needed. See ?contrasts and ?C for
> >> > relevant details and/or consult an appropriate R tutorial.
> >> >
> >> > Of course, if this is not what you meant, than ignore.
> >> >
> >> > 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 Fri, Aug 5, 2016 at 1:49 PM,   wrote:
> >> > > Hello,
> >> > >
> >> > > Your ifelse will never work because
> >> > > reasons$salutation== "Mr" & reasons$salutation=="Father" is always
> >> FALSE
> >> > > and so is reasons$salutation=="Mrs" & reasons$salutation=="Miss".
> >> > > Try instead | (or), not & (and).
> >> > >
> >> > > Hope this helps,
> >> > >
> >> > > Rui Barradas
> >> > >
> >> > >
> >> > >
> >> > > Citando Shivi Bhatia :
> >> > >
> >> > >> Dear Team,
> >> > >>
> >> > >> I need help with the below code in R:
> >> > >>
> >> > >> gender_rec<- c('Dr','Father','Mr'=1, 'Miss','MS','Mrs'=2, 3)
> >> > >>
> >> > >> reasons$salutation<- gender_rec[reasons$salutation].
> >> > >>
> >> > >> This code gives me the correct output but it overwrites the
> >> > >> reason$salutation variable. I need to create a new variable gender
> to
> >> > >> capture gender details and leave salutation as it is.
> >> > >>
> >> > >> i tried the below syntax but it is converting all to 1.
> >> > >>
> >> > >> reasons$gender<- ifelse(reasons$salutation== "Mr" &
> >> reasons$salutation==
> >> > >> "Father","Male", ifelse(reasons$salutation=="Mrs" &
> >> > reasons$salutation==
> >> > >> "Miss","Female",1))
> >> > >>
> >> > >> Please suggest.
> >> > >>
> >> > >> [[alternative HTML version deleted]]
> >> > >>
> >> > >> __
> >> > >> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> >> > >> https://stat.ethz.ch/mailman/listinfo/r-help
> >> > >> PLEASE do read the posting guide
> >> > >> http://www.R-project.org/posting-guide.htmland provide commented,
> >> > >> minimal, self-contained, reproducible code.
> >> > >
> >> > >
> >> > >
> >> > > [[alternative HTML version deleted]]
> >> > >
> >> > > __
> >> > > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> >> > > https://stat.ethz.ch/mailman/listinfo/r-help
> >> > > PLEASE do read the posting guide http://www.R-project.org/
> >> > posting-guide.html
> >> > > and provide commented, minimal, self-contained, reproducible code.
> >> >
> >>
> >> [[alternative HTML version deleted]]
> >>
> >> __
> >> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> >> https://stat.ethz.ch/mailman/listinfo/r-help
> >> PLEASE do read the posting guide http://www.R-project.org/posti
> >> ng-guide.html
> >> and pro

Re: [R] SAS file

2016-08-07 Thread Daniel Nordlund

On 8/7/2016 7:49 AM, John Kane wrote:

As Jim says the file did not arrive. R-help is very fussy about what kind of 
files it accepts. If you are still having a problem it would be a good idea to 
upload it to file-sharing place such as Dropbox or Mediafire and just post the 
link here.

John Kane
Kingston ON Canada



-Original Message-
From: r-help@r-project.org
Sent: Fri, 5 Aug 2016 10:10:13 + (UTC)
To: r-help@r-project.org
Subject: [R] SAS file

Hello,I have a SAS formatted file as attached, when I use lookup.xport i
got error below> lookup.xport("patient.ssd01")Error in
lookup.xport.inner(file) :   unable to open file: 'No such file or
directory'

can anyone please help me to figure it out?
thanksc
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.



Can't remember your password? Do you need a strong and secure password?
Use Password manager! It stores your passwords & protects your account.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.



The file extension, '.ssd01' is typically used for a standard Unix SAS 
dataset.  the R function, lookup.xport(), is for examining SAS XPORT 
files.  So, you are using the wrong approach to read the file.


You will need to get an XPORT format file, or have SAS available, or get 
some 3rd party software that will read SAS datasets.



Dan

--
Daniel Nordlund
Port Townsend, WA  USA

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] open a zip file

2016-08-07 Thread Roy Mendelssohn - NOAA Federal
If I break it into parts, I find that the "GET" fails.

>   Year <- format(Sys.Date(), "%Y")
>Month <- format(Sys.Date(), "%m")
> junk <- paste("https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/";,
+"mbs", 
+as.character(Month), 
+as.character(Year),
+".zip", 
+sep = "")
> junk
[1] "https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/mbs082016.zip";
> httr::GET("https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/mbs082016.zip";)
Response 
[https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/mbs082016.zip]
  Date: 2016-08-08 02:02
  Status: 404
  Content-Type: text/html; charset=iso-8859-1
  Size: 235 B


404 Not Found

Not Found
The requested URL /disclosure-docs/monthly/mbs082016.zip was not found on 
this server.



Your saved file will have the ending ".zip" no matter what, because that is 
what you called it, but I wouldn't be surprised if it just a txt file with the 
error message.

HTH,

-Roy

> On Aug 7, 2016, at 6:42 PM, Glenn Schultz  wrote:
> 
> paste("https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/";,
>"mbs", 
>as.character(Month), 
>as.character(Year),
>".zip", 
>sep = "")
> junk <- paste("https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/";,
+"mbs", 
+as.character(Month), 
+as.character(Year),
+".zip", 
+sep = "")
> junk
[1] "https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/mbs082016.zip";
> httr::GET("https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/mbs082016.zip";)
Response 
[https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/mbs082016.zip]
  Date: 2016-08-08 02:02
  Status: 404
  Content-Type: text/html; charset=iso-8859-1
  Size: 235 B


404 Not Found

Not Found
The requested URL /disclosure-docs/monthly/mbs082016.zip was not found on 
this server.


**
"The contents of this message do not reflect any position of the U.S. 
Government or NOAA."
**
Roy Mendelssohn
Supervisory Operations Research Analyst
NOAA/NMFS
Environmental Research Division
Southwest Fisheries Science Center
***Note new address and phone***
110 Shaffer Road
Santa Cruz, CA 95060
Phone: (831)-420-3666
Fax: (831) 420-3980
e-mail: roy.mendelss...@noaa.gov www: http://www.pfeg.noaa.gov/

"Old age and treachery will overcome youth and skill."
"From those who have been given much, much will be expected" 
"the arc of the moral universe is long, but it bends toward justice" -MLK Jr.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] open a zip file

2016-08-07 Thread Glenn Schultz
All I have this code

 #=== Function Downloads the Factor File
  #' A function to download FNMA Pool Factors
  #' 
  #' @importFrom httr GET
  #' @importFrom httr write_disk
  #' @importFrom httr http_status
  #' @importFrom httr progress
  #' @export
  FNMAPoolFactor <- function(){
Year <- format(Sys.Date(), "%Y")
Month <- format(Sys.Date(), "%m")
response <- 
  httr::GET(
paste("https://mbsdisclosure.fanniemae.com/disclosure-docs/monthly/";,
"mbs", 
as.character(Month), 
as.character(Year),
".zip", 
sep = ""),
  httr::write_disk(paste("~/FNMA/mbs/",
   as.character(Month), 
   as.character(Year),
   ".zip", 
   sep = ""), overwrite = FALSE), httr::progress())
  httr::http_status(response)
  }

Which results in a zip file but I cannot open the file with unzip or any other 
R functions what have I done wrong?

Glenn

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] R help

2016-08-07 Thread Jim Lemon
Hi Vladimir,
This may fix the NA problem:

vdat<-read.table(text="numberoftweet,tweet,locations,badwords
1,My cat is asleep,London,glum
2,My cat is flying,Paris,dashed
3,My cat is dancing,Berlin,mopey
4,My cat is singing,Rome,ill
5,My cat is reading,Budapest,sad
6,My cat is eating,Amsterdam,annoyed
7,My cat is hiding,Copenhagen,crazy
8,My cat is fluffy,Vilnius,terrified
9,My cat is annoyed,Athens,sick
10,My cat is exercising,Ankara,mortified
11,My cat is dreaming,Kracow,irked
12,My cat is mopey,Vienna,uneasy
13,My cat is glum,Brussels,upset
14,My cat is swinging,Madrid,
15,My cat is crazy,Ljubljana,",
sep=",",header=TRUE,stringsAsFactors=FALSE)

vdat$badwords[!nchar(vdat$badwords)]<-NA

badwords<-paste(vdat$badwords[!is.na(vdat$badwords)],collapse="|")

names(unlist(sapply(vdat$tweet,grep,pattern=badwords)))

Jim


On Sun, Aug 7, 2016 at 6:43 PM, Вова Грабарник  wrote:
> Hi Jim!
>
> That is exactly what I mean. Your example does the job I was looking for.
> If I refer to your example, my badwords column is not completed for all
> rows, like yours. For example it has only 10 values, but there are much more
> rows. When I try to introduce NA for blanks and write
> badwords<-paste(vdat$badwords,collapse="|")
> it collapses all values and writes smth like: word|word|NA|NA
> and if I dont introduce NAs when reading data, the outcome is still like:
> word|word|word|word
> and when I try to
> names(unlist(sapply(vdat$tweet,grep,pattern=badwords))) there is a mistake.
> I had this question before but do you know by any chance how to separate
> just those words in a column badwords and not include NA's or blanks.
>
> Thank you,
> Vladimir
>
> 2016-08-07 0:19 GMT+01:00 Jim Lemon :
>>
>> Hi Vladimir,
>> Do you want something like this?
>>
>> vdat<-read.table(text="numberoftweet,tweet,locations,badwords
>> 1,My cat is asleep,London,glum
>> 2,My cat is flying,Paris,dashed
>> 3,My cat is dancing,Berlin,mopey
>> 4,My cat is singing,Rome,ill
>> 5,My cat is reading,Budapest,sad
>> 6,My cat is eating,Amsterdam,annoyed
>> 7,My cat is hiding,Copenhagen,crazy
>> 8,My cat is fluffy,Vilnius,terrified
>> 9,My cat is annoyed,Athens,sick
>> 10,My cat is exercising,Ankara,mortified
>> 11,My cat is dreaming,Kracow,irked
>> 12,My cat is mopey,Vienna,uneasy
>> 13,My cat is glum,Brussels,upset",
>> sep=",",header=TRUE,stringsAsFactors=FALSE)
>>
>> badwords<-paste(vdat$badwords,collapse="|")
>>
>> names(unlist(sapply(vdat$tweet,grep,pattern=badwords)))
>>
>> Jim
>>
>>
>> On Sat, Aug 6, 2016 at 12:07 AM, Вова Грабарник 
>> wrote:
>> > Dear R command,
>> >
>> > I was wondering if I could ask you recommendations on my problem if that
>> > is
>> > fine with you.
>> > Basically, I have a data frame with 5 columns and 10 000 tweets
>> > recorded(rows). Those columns are: numberofatweet(number), tweet (actual
>> > textual tweet), locations(from where tweet sent), badwords(words that
>> > should not be used on twitter, that is just a column irrespective the
>> > number of a tweet and it contains only 80 rows with one word recorded in
>> > one cell.
>> > My question is whether it is possible to select only the rows which
>> > would
>> > contain such tweets, where in column "tweet"(actual text) there was one
>> > of
>> > those words from badwords column present. I tried to use grep and grepl,
>> > but nothing seems to be working.
>> >
>> > Thank you in advance,
>> > Vladimir
>> >
>> > [[alternative HTML version deleted]]
>> >
>> > __
>> > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> > https://stat.ethz.ch/mailman/listinfo/r-help
>> > PLEASE do read the posting guide
>> > http://www.R-project.org/posting-guide.html
>> > and provide commented, minimal, self-contained, reproducible code.
>
>
>
>
> --
> С уважением,
> Володя Грабарник

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Re: [R] Creating Dummy Var in R for regression?

2016-08-07 Thread Shivi Bhatia
Thank you Jeremiah and all others for the assistance. This really helped.

On Sat, Aug 6, 2016 at 5:01 AM, jeremiah rounds 
wrote:

> Something like:
>
> d  =  data.frame(score = sample(1:10, 100, replace=TRUE))
> d$score_t = "low"
> d$score_t[d$score > 3] = "medium"
> d$score_t[d$score >7 ] = "high"
> d$score_t = factor(d$score_t, levels = c("low", "medium", "high"),
> ordered=TRUE)  #set ordered = FALSE for dummy variables
> X = model.matrix(~score_t, data=d)
> X
>
>
>
> On Fri, Aug 5, 2016 at 3:23 PM, Shivi Bhatia  wrote:
>
>> Thanks you all for the assistance. This really helps.
>>
>> Hi Bert: While searching nabble i got to know R with factors variables
>> there is no need to create dummy variable. However please consider this
>> situation:
>> I am in the process of building a logistic regression model on NPS data.
>> The outcome variable is CE i.e. customer experience which has 3 rating so
>> ordinal logistic regression will be used. However most of my variables are
>> categorical. For instance one of the variable is agent knowledge which is
>> a
>> 10 point scale.
>>
>> This agent knowledge is again a 3 rated scale: high medium low hence i
>> need
>> to group these 10 values into 3 groups & then as you suggested i can
>> directly enter them in the model without creating n-1 categories.
>>
>> I have worked on SAS extensively hence found this a bit confusing.
>>
>> Thanks for the help.
>>
>> On Sat, Aug 6, 2016 at 2:30 AM, Bert Gunter 
>> wrote:
>>
>> > Just commenting on the email subject, not the content (which you have
>> > already been helped with): there is no need to *ever* create a dummy
>> > variable for regression in R if what you mean by this is what is
>> > conventionally meant. R will create the model matrix with appropriate
>> > "dummy variables" for factors as needed. See ?contrasts and ?C for
>> > relevant details and/or consult an appropriate R tutorial.
>> >
>> > Of course, if this is not what you meant, than ignore.
>> >
>> > 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 Fri, Aug 5, 2016 at 1:49 PM,   wrote:
>> > > Hello,
>> > >
>> > > Your ifelse will never work because
>> > > reasons$salutation== "Mr" & reasons$salutation=="Father" is always
>> FALSE
>> > > and so is reasons$salutation=="Mrs" & reasons$salutation=="Miss".
>> > > Try instead | (or), not & (and).
>> > >
>> > > Hope this helps,
>> > >
>> > > Rui Barradas
>> > >
>> > >
>> > >
>> > > Citando Shivi Bhatia :
>> > >
>> > >> Dear Team,
>> > >>
>> > >> I need help with the below code in R:
>> > >>
>> > >> gender_rec<- c('Dr','Father','Mr'=1, 'Miss','MS','Mrs'=2, 3)
>> > >>
>> > >> reasons$salutation<- gender_rec[reasons$salutation].
>> > >>
>> > >> This code gives me the correct output but it overwrites the
>> > >> reason$salutation variable. I need to create a new variable gender to
>> > >> capture gender details and leave salutation as it is.
>> > >>
>> > >> i tried the below syntax but it is converting all to 1.
>> > >>
>> > >> reasons$gender<- ifelse(reasons$salutation== "Mr" &
>> reasons$salutation==
>> > >> "Father","Male", ifelse(reasons$salutation=="Mrs" &
>> > reasons$salutation==
>> > >> "Miss","Female",1))
>> > >>
>> > >> Please suggest.
>> > >>
>> > >> [[alternative HTML version deleted]]
>> > >>
>> > >> __
>> > >> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> > >> https://stat.ethz.ch/mailman/listinfo/r-help
>> > >> PLEASE do read the posting guide
>> > >> http://www.R-project.org/posting-guide.htmland provide commented,
>> > >> minimal, self-contained, reproducible code.
>> > >
>> > >
>> > >
>> > > [[alternative HTML version deleted]]
>> > >
>> > > __
>> > > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> > > https://stat.ethz.ch/mailman/listinfo/r-help
>> > > PLEASE do read the posting guide http://www.R-project.org/
>> > posting-guide.html
>> > > and provide commented, minimal, self-contained, reproducible code.
>> >
>>
>> [[alternative HTML version deleted]]
>>
>> __
>> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide http://www.R-project.org/posti
>> ng-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>>
>
>

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] metaprop

2016-08-07 Thread Carlos Javier Rincon Rodriguez
hi,

i am using the funtion metaprop but when i try to save the proportion
estimation by subgrup using the option "byvar", the value in TE.fixed.w are
the transformed proportion, and i need the untranformed proportion. I try
with the option backtranf=true, but doesn`t change anithing.

 I have so many subgroup that i need to be able to save my result but i can
find where the untranformed proportion keep saving.

thanks for the help.

bye

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] changing x and y ranges in a PCA plot created by library(labdsv)

2016-08-07 Thread William Dunlap via R-help
labdsv::plot.pca() does not pass its unrecognized arguments (in ...)
to plot().  You can fix this by adding the argument ... to its call to
plot(),
right after 'main = title', in plot.pca
or by mailing the maintainer
  > maintainer("labdsv")
  [1] "David W. Roberts "
and asking him to change it.


Bill Dunlap
TIBCO Software
wdunlap tibco.com

On Sun, Aug 7, 2016 at 2:34 AM, Mohsen Sharafatmandrad <
mohsen.sharafatmand...@gmail.com> wrote:

> Hi,
>
> I want to change x and y ranges in a PCA plot created by library(labdsv).
> When I run "plot(o.pca, xlim=c(-2, 3), ylim=c(-2, 4))", nothing will
> change. I really appreciate if somebody can help on this.
>
> Cheers
>
> [[alternative HTML version deleted]]
>
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/
> posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] changing x and y ranges in a PCA plot created by library(labdsv)

2016-08-07 Thread stephen sefick
Can you provide code and data (with dput)? You will likely get an answer
more quickly.

On Sun, Aug 7, 2016 at 4:34 AM, Mohsen Sharafatmandrad <
mohsen.sharafatmand...@gmail.com> wrote:

> Hi,
>
> I want to change x and y ranges in a PCA plot created by library(labdsv).
> When I run "plot(o.pca, xlim=c(-2, 3), ylim=c(-2, 4))", nothing will
> change. I really appreciate if somebody can help on this.
>
> Cheers
>
> [[alternative HTML version deleted]]
>
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/
> posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



-- 
Let's not spend our time and resources thinking about things that are so
little or so large that all they really do for us is puff us up and make us
feel like gods.  We are mammals, and have not exhausted the annoying little
problems of being mammals.

-K. Mullis

"A big computer, a complex algorithm and a long time does not equal
science."

  -Robert Gentleman

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] SAS file

2016-08-07 Thread John Kane
As Jim says the file did not arrive. R-help is very fussy about what kind of 
files it accepts. If you are still having a problem it would be a good idea to 
upload it to file-sharing place such as Dropbox or Mediafire and just post the 
link here.

John Kane
Kingston ON Canada


> -Original Message-
> From: r-help@r-project.org
> Sent: Fri, 5 Aug 2016 10:10:13 + (UTC)
> To: r-help@r-project.org
> Subject: [R] SAS file
> 
> Hello,I have a SAS formatted file as attached, when I use lookup.xport i
> got error below> lookup.xport("patient.ssd01")Error in
> lookup.xport.inner(file) :   unable to open file: 'No such file or
> directory'
> 
> can anyone please help me to figure it out?
> thanksc
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.


Can't remember your password? Do you need a strong and secure password?
Use Password manager! It stores your passwords & protects your account.

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

[R] changing x and y ranges in a PCA plot created by library(labdsv)

2016-08-07 Thread Mohsen Sharafatmandrad
Hi,

I want to change x and y ranges in a PCA plot created by library(labdsv).
When I run "plot(o.pca, xlim=c(-2, 3), ylim=c(-2, 4))", nothing will
change. I really appreciate if somebody can help on this.

Cheers

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.