Re: [R] how to generate 2 dimensional mesh and hyper-cubes ?

2015-08-25 Thread PO SU
Tks a lot, i will study the limma package as you mentioned first ~ ~ -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2015-08-26 00:17:18, "David Winsemius" wrote: > >On Aug 25, 2015, at 4:15 AM, PO SU wrote: > >> >> >> Dear

[R] how to generate 2 dimensional mesh and hyper-cubes ?

2015-08-25 Thread PO SU
? BTW, how to find "spargraphs" this package, i find almost everywhere i know but still can not find it in R, is it a matlab package or other language package? Tks! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU _

[R] how to use nlme package to analysis mixed effect model

2015-08-04 Thread PO SU
want to know does y has relationsheep with x? how to use nlme or plm to do the  task?  the two packages seems does not have viggnette to guide me ? Does anyone happen to know ? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R

[R] A strange problem using pls package

2015-07-21 Thread PO SU
! I think the pls package must write the result into some files, and  read it back ~~ but i can't say~~ PLZ help me if you happen to know it -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list -

[R] Two stage cluster in R(two step in spss), which package implement it ?

2015-04-20 Thread PO SU
Dear, expeRts,   I am confused in finding an implementation of two stage cluster in R(which is two step cluster in spss), i do some searching, but still can not find it. Has someone happen to know it ? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU

[R] RWebdriver and RSelenium returns the same error while trying to connect the java server

2015-03-01 Thread PO SU
t 127.0.0.1 7055 after 45000ms " i don't know why, is there anybody who happens to know it ? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.e

[R] Needing help about recosystem package

2015-02-05 Thread PO SU
happen to know it ? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ 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

Re: [R] How to build a vignette?

2014-12-06 Thread PO SU
OK, I got it , you helped me  a lot , tks very much. :) -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-12-06 14:12:45, "Jeff Newmiller" wrote: >If you run R CMD check on your package successfully, then that file will be >generated as needed a

Re: [R] How to build a vignette?

2014-12-06 Thread PO SU
ckage, source R codes are already written but i don't very clear about how to subbmmit to cran.   -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-12-06 11:12:32, "Jeff Newmiller" wrote: >You are not talking about a vignette. That is the pdf vers

[R] How to build a vignette?

2014-12-05 Thread PO SU
g function documents from .Rd files, how can i do?  TKS.   -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE d

[R] using win task to run Rscript somepackages can't work in script mode

2014-12-01 Thread PO SU
different between the two ways, the gmailr package fails work in the script mode.     So, what the difference? why Rscript can't run some codes which works well in Rstudio? How can i do something to make it suceess if there is some options to set ?      -- PO SU mail: desolato...@163.com Ma

[R] problem when using gmailr

2014-11-12 Thread PO SU
task. TKS  -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide

Re: [R] how to use the rpart model to predict new data frame?

2014-11-11 Thread PO SU
OK , i tried predict(rp,b) but showed me a result which i can't understand, now it's the argument  type="vector" worked. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-11-12 11:55:08, "Bharat Bargujar" wrote: HI,   Try this:

[R] how to use the rpart model to predict new data frame?

2014-11-11 Thread PO SU
Dear expeRts,     Now i have a  train  dataset a  and  test dataset b , i  using the following codes: rp<-rpart(y~.,data=a,method="class") plot(rp) text(rp) but how can i use the trained model to predict b? TKS. -- PO SU mail: desolato...@163.com Majored in Statist

Re: [R] how to calculate a numeric's digits count?

2014-10-23 Thread PO SU
find<-function(x) { str<-as.character(x) if(is.na(strsplit(str,"\\.")[[1]][2])) return(0) else return(nchar(strsplit(str,"\\.")[[1]][2])) } But when i  find(1.340)  i get 2 not 3. find(1.3400) will also get 2 not 4. So,my question is how to implement the ab

[R] how to calculate a numeric's digits count?

2014-10-23 Thread PO SU
ys be transformed autolly to 1.34? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.htm

[R] HOW to call R code from matlab?

2014-10-19 Thread PO SU
Dear expeRts,    I am fammilar with matlab , i want to call some r codes from it , what can i refer?  I tried R.matlab. But it seems can't work well. so, do you have any other suggestions? -- PO SU mail: desolato...@163.com Majored in Statistics from

[R] How to read tif format file?

2014-10-19 Thread PO SU
hat's wrong with readGDAL? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html

Re: [R] how to overwrite a Unary operator ?

2014-10-19 Thread PO SU
wo params. Is it true? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-18 00:54:40, "Greg Snow" <538...@gmail.com> wrote: >You may be interested in looking at Reference Classes/objects (see >?setRefClass). This is a form of OO programming

Re: [R] how to overwrite a Unary operator ?

2014-10-19 Thread PO SU
TKS , but i still have a question that maybe i can write a new S3 method for +, but how can i create a new operator which can pass one param? becasue + is far away from ++ to let me know that 2 will be 3. So, it's still a question.. -- PO SU mail: desolato...@163.com Major

Re: [R] how to judge a virable is a integer?

2014-10-18 Thread PO SU
r last suggestion using floor. and also tks for other helpers! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-18 22:48:15, "Sergio Fonda" wrote: Sorry for my previous hurry misunderstanding. Try this link: http://stackoverflow.com/questions/3476782

Re: [R] how to judge a virable is a integer?

2014-10-18 Thread PO SU
It's due to that, 1 is a numeric, 1.2 is a numeric, though it's true. but deeply, when i want to know 1 is an integer,  there seems no easy way to get the answer. So, is there anyone happen to know it? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 201

Re: [R] how to judge a virable is a integer?

2014-10-18 Thread PO SU
But i use a<-10/b ,  b is some value ,may be  5, maybe 5.5  not in the form  xxL ,so how can i do in the situation to judge a ? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-18 18:58:48, "Berend Hasselman" wrote: > >On 18-10-2014, at

[R] how to judge a virable is a integer?

2014-10-18 Thread PO SU
Dear usRers,    I want to judge virable is or not a integer?   e.g.  is.integer(1)  FALSE   because it is a numeric, but i want it's true. as.integer may not be used. because i don't know a is 1 or 1.1. -- PO SU mail: desolato...@163.com Majored in Statistics

Re: [R] how to overwrite a Unary operator ?

2014-10-17 Thread PO SU
from it?  -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-17 15:16:47, "David Winsemius" wrote: > >On Oct 16, 2014, at 10:36 PM, PO SU wrote: > >> >> Tks for your advice, let the ++ problem alone, how to write an >

Re: [R] how to overwrite a Unary operator ?

2014-10-16 Thread PO SU
Tks for your advice,  let the ++ problem alone, how to write an Unary operator ? Is it permitted in R? suchas    a<-2 , a%+2%  will let a  be 4 . I just want to know it , i won't pollute r with it , because i know what is r .  : ) -- PO SU mail: desolato...@163.com Ma

[R] how to overwrite a Unary operator ?

2014-10-16 Thread PO SU
e function need two params like   a%++%b , how to write a function needing just one param? TKS ! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEAS

[R] how to ajust y-axis values in plot() ?

2014-10-14 Thread PO SU
ready plot a plot like plot(11:20) , but when i abline(h=40), i found it will go out of the plot even after i used abline(h=40,xpd=T). SO, may you help me? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org ma

[R] Not related with R, but i want to jion in a statistics help maillist, can you tell me some ?

2014-10-12 Thread PO SU
Dear usRers,     I  have some statistic problems, and i want to join a Professional maillist for it. can you tell me some maillists?TKS! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list

Re: [R] complain about a[-integer(0)]

2014-10-11 Thread PO SU
Tks, i have to do it. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-11 17:57:40, "Jim Lemon" wrote: >On Sat, 11 Oct 2014 05:25:14 PM PO SU wrote: >> Dear helpeRs, >> let a <- 1:10 >> let b <- integer(0

[R] complain about a[-integer(0)]

2014-10-11 Thread PO SU
a oppisite case that a[-integer(0)] need to be integer(0) ? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide h

Re: [R] Count number of Fridays in a month

2014-10-10 Thread PO SU
ay in ?POSIXlt  ?format  ? strptime and other related keywords's document. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-10 19:44:17, "Duncan Murdoch" wrote: >On 10/10/2014, 7:28 AM, Abhinaba Roy wrote: >> Hi R helpers, >> >&

Re: [R] how to break the loop using sapply?

2014-10-10 Thread PO SU
UT. when it let OUT=TRUE. sapply should be break.......... -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-10 14:44:47, "Hervé Pagès" wrote: >Hi, > >On 10/09/2014 11:12 PM, PO SU wrote: >> >> >> Is that mean while may be m

Re: [R] how to break the loop using sapply?

2014-10-09 Thread PO SU
ust use apply functions. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-10-10 13:58:29, "Jeff Newmiller" wrote: >Don't use apply functions if you want to do what you describe. They don't work >

[R] how to break the loop using sapply?

2014-10-09 Thread PO SU
t may need break at i=5 or at i=5, for the possible of the  last case, i don't use for loop, because it slow(is it right?). So,if you happen to know it ,may you help me? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU _

Re: [R] simulation data in SEM

2014-09-14 Thread PO SU
PLZ mke sure the package installed which contains "mvrnorm" function. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-14 09:56:34, "thanoon younis" wrote: >Dear R members >I want to simulate data depending on SEM and when i appli

Re: [R] using pdf(file="") encount a Chinese garbled

2014-09-12 Thread PO SU
Tks, it works now , just needing some extra ajustment. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-12 12:33:19, "Jinsong Zhao" wrote: >On 2014/9/11 21:10, PO SU wrote: >> >> Dear expeRts, >> When i use the following

[R] using pdf(file="") encount a Chinese garbled

2014-09-11 Thread PO SU
quot;) to R plot viewer, it's ok .   Is there anyone happen to know the solution? BTW, i explore the encoding argument in ?pdf ,but still can't solve the problem. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __

Re: [R] some question about vector[-NULL]

2014-09-11 Thread PO SU
Actually, i  thought  the way: a<-1:3 b<-NULL or 2 a[-b] will not work if b is NULL A<-c(a,1) B<-c(b,length(A)) A[-B] will get the same result as if b is NULL get a, if b is 2 get a[-2] I think it works well  in considering memory use or efficiency or code tidy. -- PO SU ma

Re: [R] some question about vector[-NULL]

2014-09-11 Thread PO SU
Orignally i don't want to do the if ( length) check because i know that in a 1 loops, after may be 10 or 20 or 100 loops , "i" will not be empty. so i mean , in the left loops, i would always check something not needed to check which i would not like to do.   -- PO SU

Re: [R] some question about vector[-NULL]

2014-09-11 Thread PO SU
It really suprise me that a[-c(0,1,2)] works as a[-c(1,2)]. But, unfortunately, a[-0] still can't work . That 's mean: i want: a<-1:3 a[-0] > 1 2 3 or a[-NULL] > 1 2 3 -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-11 02:24:25, "

[R] unable to move temporary installation when install some packages

2014-09-10 Thread PO SU
e one happen to know the solution? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting

Re: [R] some question about vector[-NULL]

2014-09-10 Thread PO SU
en iv is c(2,6) and so on...   -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-11 01:58:46, "Duncan Murdoch" wrote: >On 10/09/2014 12:20 PM, William Dunlap wrote: >> Can you make your example a bit more concrete? E.g., is your &

Re: [R] some question about vector[-NULL]

2014-09-10 Thread PO SU
May be i could add a extra elment to B,that's: F<-function( C ) { C<-C[-A] some processing... res<-NULL or some new index not included in A return(res) } so in a loop, C<-c(B,1) tmpindex<-length(C) A<-tmpindex for( i in 1:10) { D<-F(C) A<-c(A,D) } -- PO

Re: [R] some question about vector[-NULL]

2014-09-10 Thread PO SU
t included in A return(res) } May be after 5 or 10 loops, A would already not NULL, so the added if ..else statement would be repeated in left loops which i would not like to see. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-10 06:45:59, "Dun

[R] some question about vector[-NULL]

2014-09-10 Thread PO SU
there all get NULL 2.The most important thing: a<-1:10 b<-NULL or 1 a<-c(a,b) will work so i don't need to know whether b is null or not,but: a[-NULL] can't work!!  i just need a[-NULL]==a , how can i reach this purpose?     -- PO SU mail: desolato...@163.com

Re: [R] How to use multi paragraph comment like /* and */ in cpp?

2014-09-09 Thread PO SU
Tks for all your help,  finally i choose the way in Rstudio ctrl+shift+C, and do twice to cancel those comments. It's enough for me now. BTW, I also like the way: if(FALSE) {}   :) -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-10 02:15:49, "

Re: [R] How to use multi paragraph comment like /* and */ in cpp?

2014-09-08 Thread PO SU
ng Rstudio, after lots trying, i find that ctrl+shift+C can do the thing. Also i investgate roxygen, but it seems needing to learn the whole package ,  if some one happen to know how to do in roxygen, may you give me a quick reference? -- PO SU mail: desolato...@163.com Majored in Stati

[R] How to use multi paragraph comment like /* and */ in cpp?

2014-09-08 Thread PO SU
Dear expeRts,    I find it's terrible  when  i want to comment multi paragraph (e.g.  a 30 lines function) , i have to comment each line with #,  is there any good way to do that ?    I investgate it, but found no easy way, may you help me ? -- PO SU mail: desolato...@163.com Major

Re: [R] using edit to extract codes from vignette failed

2014-09-08 Thread PO SU
OK, i get it, i should set the editor argument , i don't know how to report a bug to Rstudio, may you do that  ?   -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-09 00:41:33, "William Dunlap" wrote: >Complain to the RStudio people - R

Re: [R] using edit to extract codes from vignette failed

2014-09-08 Thread PO SU
itle) : argument "name" is missing, with no default -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-09-08 05:46:39, "Karl Ropkins" wrote: >Try: > >edit(vignette("grobs",package = "grid")) > >(edit

[R] using edit to extract codes from vignette failed

2014-09-07 Thread PO SU
I investigated edit function, but still can't  get codes from a vignette, May you help me? -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PL

[R] The newest version of Rstudio Desktop v0.98.1049 couldn't be installed

2014-09-03 Thread PO SU
Dear expeRts,    I find the newest Rstudio Desktop v0.98.1049  for windows is not newest, after i installed, it was a old version. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https

[R] what happened when copying a function definition into R prompt then press Enter?

2014-08-30 Thread PO SU
Dear expeRts,     That's to say,what happened when loading source code  into memory? what's the difference between it and loading installed code into memory? Do they related with .Rdata?             -- PO SU mail: desolato...@163.com Majored in Statistics

[R] what 's meaning of setting options() through .onLoad() funtion in making a package?

2014-08-29 Thread PO SU
= list() ) toset <- !(names(op.devtools) %in% names(op)) if(any(toset)) options(op.devtools[toset]) invisible() } -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

[R] 21 R navigation tools

2014-08-27 Thread PO SU
I think the article from burns-stat is very worth reading , You can google it ,and hope you find it useful. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

Re: [R] What the difference between .Golbalenv and package:base?

2014-08-26 Thread PO SU
nment() can work well. Tks! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-27 00:02:07, "William Dunlap" wrote: >as.environment(characterString) maps an entry from the output of >search() to the environment at the named position in the search

Re: [R] What the difference between .Golbalenv and package:base?

2014-08-25 Thread PO SU
In one word, as.environment(x), x is somthing not the environment's name.  But, when i add a environment into the search() list, after i attr(newenvir,"name")<-"new_name" I can use the  as.environment("new_name") to obtain the added environment. (why?) Ho

Re: [R] What the difference between .Golbalenv and package:base?

2014-08-25 Thread PO SU
uot;package:stats" attr(,"path") [1] "C:/Program Files/R/R-3.1.1/library/stats" I am really confused now, while as.environment("package:stats") can be work by convert the name of the environment stats, the environmentName returns "" ! And get the .Gl

Re: [R] What the difference between .Golbalenv and package:base?

2014-08-25 Thread PO SU
u understand my meaning for my pool english expression way. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-25 09:53:37, "John McKown" wrote: >On Mon, Aug 25, 2014 at 1:07 AM, PO SU wrote: >> >> >> Dear rusers, >> >>

[R] What the difference between .Golbalenv and package:base?

2014-08-24 Thread PO SU
lways convert the name to the environment, How can i just use the following form: > tmp<-attach(NULL,name="new_name") > assign("a",2,envir=new_name)   #like using  .GlobalEnv > a [1] 2 > new_name$a [1] 2 -- PO SU mail: desolato...@163.com Majored in Statist

Re: [R] hadley's book

2014-08-21 Thread PO SU
Haha, i have already read the advanced r programming part of the book. As you said, it will be quite popular in future years. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-22 04:57:01, "Mark Leeds" wrote: >I have a feeling hadley's

Re: [R] file.show() may have some bug?

2014-08-21 Thread PO SU
Because the update of R is rather a trouble thing, i mean that you should have to install every package you have installed. So i do not follow the newest version. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-21 04:40:10, "peter dalgaard" wrote

Re: [R] file.show() may have some bug?

2014-08-21 Thread PO SU
Sorry for my bad typing, file.show("xxx.h") still not work. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-21 03:12:06, "Berend Hasselman" wrote: > >On 21-08-2014, at 05:19, PO SU wrote: > >> Dear Rusers, >>

[R] file.show() may have some bug?

2014-08-20 Thread PO SU
Dear Rusers, when i try file.show(" xxx.h") in Rstudio which using R3.0.2, it doesn't show anything. But when i use file.edit("xxx.h"),it shows the right file, It is the same thing happen to xxx.c file. May you explain it to me? -- PO SU mail: desolato...@163.

Re: [R] A question in Rinternals.h

2014-08-19 Thread PO SU
BTW, you say i always send html format email, finally i find that it is my mail server which send mail in html format by default., i should change the format eveytime before sending a mail... -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-19 06:28:06

Re: [R] A question in Rinternals.h

2014-08-19 Thread PO SU
Tks for your guide, but before i know which maillist should i ask the question, i could only ask it here. 'figure out' i mean 'understand'. Forgive my pool english :). -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-19 06:28:06, "

[R] A question in Rinternals.h

2014-08-19 Thread PO SU
meaning, they seem like function declarations, Rf_XXX maybe function pointers? I need your help. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

Re: [R] Just stumbled across this: Advanced R programming text & code - from Hadley

2014-08-11 Thread PO SU
The book is absolutely helpful to me. Any R newusers should read the book. Now I am reading the Section Rcpp. -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-11 09:02:53, "Mitchell Maltenfort" wrote: >Ah, what do you know anyway? -- as the boo

[R] Need help in using Rcpp

2014-08-11 Thread PO SU
rt of a list then return a LogicalVector, but i can't understand if the first element of the LogicalVector is true then return the row index of the list. Tks! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU [[alternative HTML ve

Re: [R] loops with assign() and get()

2014-08-11 Thread PO SU
t;> names(dfi)=names(tmp[c(1,4,5)]) >> dfi=rbind(dfi,tmp[c(1,4,5)]) >> names(dfi)=c("UID","Date","Location") >>} NB: The code above without any test! -- PO SU mail: desolato...@163.com Majored in Statistics from SJTU At 2014-08-10 06:32:38,