Re: [R] Unable to compile & install rggobi

2012-04-27 Thread Prof Brian Ripley
On 28/04/2012 04:33, Michael Lawrence wrote: GGobi needs a 64 bit binary before we can get rggobi available on Windows again. Only true for 64-bit R on Windows, which is nowadays the primary Windows version. But that does not apply to the on-extended-support Windows XP which is 32-bit only.

Re: [R] Unable to compile & install rggobi

2012-04-27 Thread Michael Lawrence
GGobi needs a 64 bit binary before we can get rggobi available on Windows again. On Fri, Apr 27, 2012 at 6:27 PM, Indrajit Sengupta wrote: > I came across this web site: > > http://cran.r-project.org/bin/windows/contrib/2.15/check/ > > Where I checked the file: rggobi-check.log > > The contents o

Re: [R] multivariate xts merge question

2012-04-27 Thread R. Michael Weylandt
If I understand what you are looking to do, this might be the most efficient: y < - apply(x,1,function(y,ns) procState(y,ns), colnames(x)) y <- as.xts(do.call(rbind, y)) merge(x, y) But you might benefit from looking at zoo::rollapplyr() rather than apply -- I think the result will be an xts (or

Re: [R] Unable to compile & install rggobi

2012-04-27 Thread Indrajit Sengupta
I came across this web site:   http://cran.r-project.org/bin/windows/contrib/2.15/check/   Where I checked the file: rggobi-check.log   The contents of this file is giving the same kind of error that I am facing. Does that mean, this package does not work with R 2.15 yet? Is it a bug?   Regards, I

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread R. Michael Weylandt
There's a link to it at the end of every R-Help posting. Michael On Apr 27, 2012, at 5:47 PM, Hans Thompson wrote: > Where can I find the posting guide? I've been trying to use "A handbook of > Statistical Analyses Using R" and google searching but I will be reading "An > Introduction to R"

[R] generate random numbers for lotteries

2012-04-27 Thread Vale Fara
 Hi, I am working with lotteries and I need to generate two sets of uniform random numbers. Requirements: 1) each set has 60 random numbers 2) random numbers in the first set are taken from an interval (0-10), whereas numbers in the second set are taken from a higher interval (15-25) 3) numbers ge

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread Hans Thompson
Where can I find the posting guide? I've been trying to use "A handbook of Statistical Analyses Using R" and google searching but I will be reading "An Introduction to R" now that I see its better to starting out then using the "?function". sorry. -- View this message in context: http://r.78969

Re: [R] R2HTML output shows NULL

2012-04-27 Thread Jeff Newmiller
The key rule on this list is to post R code. And HTML is text in its raw form, so posting HTML source in a text message works fine, especially if it is trimmed to just show context. It is when the message itself is sent with MIME coding set to HTML that the formatting gets messed up and expectat

Re: [R] R2HTML output shows NULL

2012-04-27 Thread Joshua Wiley
On Fri, Apr 27, 2012 at 2:52 PM, Greg Snow <538...@gmail.com> wrote: > Jeff, there are also many times that people are told not to post HTML, > so this case would be a bit of a Catch 22.  Also some of us (well me > at least, I expect others have as well) have experienced this already > and fully un

Re: [R] R2HTML output shows NULL

2012-04-27 Thread Erin Hodgess
Hello! Thank you. I figured out the solution. In the HTML.title function, there is an argument CSSstyle which is set to NULL by default. If I put " " in there, all is well. Sincerely, Erin On Fri, Apr 27, 2012 at 4:52 PM, Greg Snow <538...@gmail.com> wrote: > Jeff, there are also many times

Re: [R] expression() and font.lab ?

2012-04-27 Thread Hermes
Thank you David. Regards, Aparna On 27 Apr 2012, at 22:44, David Winsemius wrote: > converted formated text to plain text. > On Apr 27, 2012, at 3:52 PM, Aparna Radhakrishnan wrote: > >> Hi...sorry that my question seemed incomplete. >> >> The plotting code : >> par >> (cex >> .axis >> = >>

Re: [R] R2HTML output shows NULL

2012-04-27 Thread Greg Snow
Jeff, there are also many times that people are told not to post HTML, so this case would be a bit of a Catch 22. Also some of us (well me at least, I expect others have as well) have experienced this already and fully understand what is being discussed without needing an example (and for this cas

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread David Winsemius
On Apr 27, 2012, at 3:04 PM, Hans Thompson wrote: Thank you to everyone in this forum that has been helping me with the basic R skills while I learn to apply them. I would like to take the coefficient of two coordinates. The coefficient of what? One of them comes Them? from tw

Re: [R] determining if a function exists in a particular package

2012-04-27 Thread William Dunlap
> I looked at exists and objects, but they seem to refer to an > environment rather than a package. Those functions work with the names of attached packages, but you have know that the name of an attached package has "package:" prefixed to the package's usual name. E.g., > exists("lm", "package

Re: [R] expression() and font.lab ?

2012-04-27 Thread David Winsemius
converted formated text to plain text. On Apr 27, 2012, at 3:52 PM, Aparna Radhakrishnan wrote: Hi...sorry that my question seemed incomplete. The plotting code : par (cex .axis = 0.8,las=1,font.lab=2,font.axis=2,family="sans",mgp=c(2,1,0),mar=c(3, 3, 4, 2)+0.1) plot(A$pos,-log(A$GPVI_frequen

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread Sarah Goslee
You mean like a linear regression? ?lm You might benefit from reading at the very least An Introduction to R and the posting guide to this list. Sarah On Fri, Apr 27, 2012 at 5:08 PM, Hans Thompson wrote: > I meant (1,1) as an (x,y) coordinate.  I am trying to find the function to > return the

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread Bert Gunter
Have you read "An Introduction to R" or other basic R tutorial? I don't completely understand what you're asking (I was unable to decipher"coefficients of two coordinates") , but it seems shockingly basic. Before posting to this list, you should at least make some effort to learn basic skills on yo

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread Hans Thompson
I meant (1,1) as an (x,y) coordinate. I am trying to find the function to return the coefficient of the line running through: >B x y a 1 1 and all the points in: >A x y a 1 3 b 2 2 c 3 1 hope that is more clear. Thanks again Rui. -- View this message in context: htt

Re: [R] Returning the coef from two coordinates

2012-04-27 Thread Rui Barradas
Hello, Hans Thompson wrote > > Thank you to everyone in this forum that has been helping me with the > basic R skills while I learn to apply them. > > I would like to take the coefficient of two coordinates. One of them > comes from two different columns in a table: > > >>A > x y

Re: [R] To make a graph for 4 functions

2012-04-27 Thread Rui Barradas
Hello, quantum wrote > > How can I use the curve when I have a vector? How should the R code look > like? > You can't. From the manual: "expr The name of a function, or a call or an expression written as a function of x which will evaluate to an object of the same length as x." Your functi

[R] Hyperspec package: need to change spectra names in a stacked plot

2012-04-27 Thread Roberto
Hi all, I need to insert the name of spectra in a stacked plot obtained with hyperspec. I use this command plot(spectra [c(-1:-4, -6:-8, -10:-12, -14:-16)], stacked = T) but, in this way R draw nameless spectra on the Y axis. How can I solve the problem? Thank you for any suggestion. Best rega

Re: [R] determining if a function exists in a particular package

2012-04-27 Thread Gabor Grothendieck
On Fri, Apr 27, 2012 at 5:13 PM, Erin Hodgess wrote: > I found the solution in an old post: > > It's > lsf.str("package:ts") > > for functions. > > Cool! > Note that that gives exported functions. If you also want internal functions in addition to the exported ones then try this: library(ts) ls

Re: [R] To make a graph for 4 functions

2012-04-27 Thread quantum
How can I use the curve when I have a vector? How should the R code look like? -- View this message in context: http://r.789695.n4.nabble.com/To-make-a-graph-for-4-functions-tp4592941p4593672.html Sent from the R help mailing list archive at Nabble.com. __

[R] Returning the coef from two coordinates

2012-04-27 Thread Hans Thompson
Thank you to everyone in this forum that has been helping me with the basic R skills while I learn to apply them. I would like to take the coefficient of two coordinates. One of them comes from two different columns in a table: >A x y a 1 3 b 2 2 c 3 1 the other is set and

Re: [R] Selecting columns whose names contain "mutated" except when they also contain "non" or "un"

2012-04-27 Thread Paul Miller
Hi Greg, This is very helpful. Thanks for explaining it. I'm clearly going to need to improve my understanding of regular expressions. Currently busy trying to figure out Sweave and knitr though. Paul --- On Thu, 4/26/12, Greg Snow <538...@gmail.com> wrote: > From: Greg Snow <538...@gmail.com

Re: [R] expression() and font.lab ?

2012-04-27 Thread Aparna Radhakrishnan
Hi...sorry that my question seemed incomplete. The plotting code : par(cex.axis=0.8,las=1,font.lab=2,font.axis=2,family="sans",mgp=c(2,1,0),mar=c(3, 3, 4, 2)+0.1) plot(A$pos,-log(A$GPVI_frequentist_add_Batch_expected_pvalue,10),col=A$R2class,pch=A$pch,xlim=c(161160087,161214038),ylim=c(0,7),xlab=

Re: [R] panel cointegration

2012-04-27 Thread phillen
I found the unit root test function /purtest/ in the plm package but nothing spefifical about cointegration. I really would be grateful if anyone knew about a package for panel cointegration tests. best regards, Philipp -- View this message in context: http://r.789695.n4.nabble.com/panel-cointegr

Re: [R] determining if a function exists in a particular package

2012-04-27 Thread Sarah Goslee
You can also use exists(): > library(MASS) > exists("loglm", where=search()[grepl("MASS", search())]) [1] TRUE > exists("loglmx", where=search()[grepl("MASS", search())]) [1] FALSE As for lsf.str(), this only works for loaded packages. You didn't specify whether you needed to be able to search loa

Re: [R] determining if a function exists in a particular package

2012-04-27 Thread Erin Hodgess
I found the solution in an old post: It's lsf.str("package:ts") for functions. Cool! On Fri, Apr 27, 2012 at 4:12 PM, Mark Leeds wrote: > Hi Erin: I don't know how to do it programatically but it might be quicker > to just > go to the vignette and click on it. All the functions should be in th

[R] determining if a function exists in a particular package

2012-04-27 Thread Erin Hodgess
Hello R People: Is there a way to determine if a function exists in a particular package, please? I looked at exists and objects, but they seem to refer to an environment rather than a package. I was thinking of something like: ifelse(exists(functiona) in MASS, print(1:10), print(5)) Thanks, E

Re: [R] Deleting observations from baseline that don't appear in follow up

2012-04-27 Thread Jeff Newmiller
Read ?merge --- Jeff NewmillerThe . . Go Live... DCN:Basics: ##.#. ##.#. Live Go... Live: OO#.. Dead: OO#.. Playing Research Eng

Re: [R] Deleting observations from baseline that don't appear in follow up

2012-04-27 Thread Sarah Goslee
What about baseline[baseline$id %in% follow.up$id, ] or the same thing but using subset(). Sarah On Fri, Apr 27, 2012 at 4:36 PM, justin jarvis wrote: > Hello all, > I'm almost embarrassed to post this , it seems so easy.  Suppose I have a > baseline and follow up survey but some people are mi

[R] Deleting observations from baseline that don't appear in follow up

2012-04-27 Thread justin jarvis
Hello all, I'm almost embarrassed to post this , it seems so easy. Suppose I have a baseline and follow up survey but some people are missing in the follow up: > baseline<-data.frame(id=c(3,5,7,9,12), data= runif(5)) > follow.up<-data.frame(id=c(3,7,9,12), data= runif(4)) > baseline id da

Re: [R] R2HTML output shows NULL

2012-04-27 Thread Jeff Newmiller
Haven't you been asked to provide an example of code that illustrates your problem often enough by now to anticipate the request in your first post? --- Jeff NewmillerThe . . Go Live.

[R] R2HTML output shows NULL

2012-04-27 Thread Erin Hodgess
Hello R People: I am using the R2HTML program for the first time (actually yesterday), and I have a question, please: I am getting NULL in the webpage in several places, presumably where NULL would appear on the screen. How would I go about fixing that, please? Thanks, Erin -- Erin Hodgess A

Re: [R] Wrap names.arg text in barplot

2012-04-27 Thread Kyle.
Oh! Great idea. I'll give that a try. ---Kyle. On Fri, Apr 27, 2012 at 12:00 PM, William Dunlap wrote: > You can use strwrap and paste to insert newlines into your labels. E.g., > > > wrapped <- function(strings, width) vapply(strings, > function(s)paste(collapse="\n", strwrap(s, width)), FU

Re: [R] Wrap names.arg text in barplot

2012-04-27 Thread William Dunlap
You can use strwrap and paste to insert newlines into your labels. E.g., > wrapped <- function(strings, width) vapply(strings, > function(s)paste(collapse="\n", strwrap(s, width)), FUN.VALUE="", > USE.NAMES=FALSE) > par(mfrow=c(2,1)) > barplot(structure(11:15, names=wrapped(state.name[31:35],

Re: [R] panel cointegration

2012-04-27 Thread David Winsemius
On Apr 27, 2012, at 2:38 PM, phillen wrote: Hi - i am looking for a package with which I can perform panel cointegration tests. Old threads suggest plm and urca package, but I don't find suitable tests in these packs. Somebody knows more? best regards, Philipp http://cran.r-project.org/we

Re: [R] To make a graph for 4 functions

2012-04-27 Thread R. Michael Weylandt
Use curve() like Rui said. Michael On Fri, Apr 27, 2012 at 1:48 PM, quantum wrote: > Thanks for your response. > > Now I have 3 functions for example > > y0<-function(x) x^2 > y1<-function(x) x^3 > y2<-function(x) x^5 > > t<-function(x) c(y0(x),y1(x),y2(x)) > > I want to plot this so I get 3 gra

[R] RODBC 1.3-5 under cygwin 1.7.12-1

2012-04-27 Thread Dario Buttari
I am using R 2.14.2-1 under cygwin 1.7.12-1 in Windows 7 Professional Service Pack 1. In the past I found very desirable to modify the RODBC package to access the Windows ODBC connections in R under cygwin: http://sourceforge.net/mailarchive/forum.php?thread_name=CAPCJcd5K7-9TdK6AqEzy9XpBVw68QeOYz

[R] panel cointegration

2012-04-27 Thread phillen
Hi - i am looking for a package with which I can perform panel cointegration tests. Old threads suggest plm and urca package, but I don't find suitable tests in these packs. Somebody knows more? best regards, Philipp -- View this message in context: http://r.789695.n4.nabble.com/panel-cointegrati

[R] kiteChart to show real values with scalebar

2012-04-27 Thread bodiless
Dear R-users I hope someone could help me on this problem. I want to create a multiple kiteChart showing the real values with a scalebar on each indicating the scale . Here are some sample data to show what I want to achieve. Y <- read.table(textConnection("Sample1 Sample2

Re: [R] To make a graph for 4 functions

2012-04-27 Thread quantum
Thanks for your response. Now I have 3 functions for example y0<-function(x) x^2 y1<-function(x) x^3 y2<-function(x) x^5 t<-function(x) c(y0(x),y1(x),y2(x)) I want to plot this so I get 3 graphs in a diagram. How can I do this? plot(x,t(x),type="l") doesnt work. -- View this message in cont

Re: [R] Min , Max

2012-04-27 Thread R. Michael Weylandt
Yes, like I said, you don't need to be subsetting h: h = listoffiles[n] then later just use h Michael On Fri, Apr 27, 2012 at 2:22 PM, Jonsson wrote: > this is what happened with me:that when I get to the second element h[n] > becomes h[2] which > doesn't exist (h[1] obviously did). > Any sugg

Re: [R] expression() and font.lab ?

2012-04-27 Thread David Winsemius
On Apr 27, 2012, at 11:22 AM, aparna15 wrote: Hi.. I managed to use expression() for superscripting and subscripting values in my axis labels. What's missing here is your plotting code and your machine and R installation details. You may want to review the Posting Guide for what is re

Re: [R] Min , Max

2012-04-27 Thread Jeff Newmiller
a) don't double post b) provide context... the majority of R-helpers do not use nabble c) read and believe the error message... don't subscript on a vector known to have one element. --- Jeff NewmillerT

[R] Wrap names.arg text in barplot

2012-04-27 Thread Kyle.
Hello! Does anyone know of a handy way to wrap the names.arg text in a barplot? I'm creating a bar plot with rather long labels; I can adjust the margins, but I'd also like to have the text wrap to about 4cm. Thanks! Kyle H. Ambert Doctoral Candidate, Bioinformatics Oregon Health & Science Unive

Re: [R] Min , Max

2012-04-27 Thread Jonsson
this is what happened with me:that when I get to the second element h[n] becomes h[2] which doesn't exist (h[1] obviously did). Any suggestions -- View this message in context: http://r.789695.n4.nabble.com/Min-Max-tp4593065p4593402.html Sent from the R help mailing list archive at Nabble.com.

Re: [R] Min , Max

2012-04-27 Thread Jonsson
this is what happened with me:that when I get to the second element h[n] becomes h[2] which doesn't exist (h[1] obviously did). Any suggestions -- View this message in context: http://r.789695.n4.nabble.com/Min-Max-tp4593065p4593401.html Sent from the R help mailing list archive at Nabble.com.

Re: [R] Min , Max

2012-04-27 Thread Jonsson
Yes this what I meant. I think no need for this line h=listfile[[n]],if I can just put it directly in the other line to do the calculations for every file in my list.they are not really elements.they are files. what I need is just this:get the size of each file in my list then /67420/4,to get t

Re: [R] Batch importing data

2012-04-27 Thread David Winsemius
On Apr 27, 2012, at 1:30 PM, R. Michael Weylandt wrote: list.files() will give you all the file names in your working directory (you can also give it a pattern argument) then can loop over those with something like: lapply(list.files(), read.table) which will put all your files in a list obje

Re: [R] One main title and One legend for multiple lattice plots

2012-04-27 Thread Elliot
How would I do something like xyplot(y + z + w ~ x | v, groups = n, data = dat, main = "My Title", auto.key = TRUE) I want the output to be an array of panels, with a column for each value of v, a row for each of y, z, and w, and with each row having a different y-axis scale (but the same scale w

Re: [R] PLM package PGGLS strange behavior

2012-04-27 Thread Ruben de Bliek
Hi. I can confirm my version of R to be of number 2.14.2, PLM 1.2-8. My system: X86 Pentium dualc. t2390 32bit, 3gb internal memory. Windows 7 build 7601, Service Pack 1. This machine has actually just received a clean Windows 7 install. The estimated estimates do not match the correct ones. Furth

Re: [R] find the eigenvector corresponding to the largest eigenvalue

2012-04-27 Thread David Winsemius
On Apr 27, 2012, at 11:41 AM, Rebecca wrote: Hi, If I use the eigen() function to find the eigenvalues of a matrix, how can I find the eigenvector corresponding to the largest eigen value? After reading the help page, I would have assumed that since the eigenvalues are sorted, that the

Re: [R] Min , Max

2012-04-27 Thread Rui Barradas
Hello, Jonsson wrote > > Dear Rui, > > I really appreciate your help. This is exactly what I was looking for.I > know there is simpler way than mine but I couldn't figure it out.So, many > many thanks. > > I wonder what is the difference between > > This:tm[ta[i],tb[i]]= round(mean(D[(d-

Re: [R] Min , Max

2012-04-27 Thread R. Michael Weylandt
Just a total guess but if h is the n-th element of listfile, do you really mean to be taking the n-th element of h as well? It could be that when you get to the second element h[n] becomes h[2] which doesn't exist (h[1] obviously did) If you do mean this, listfile is probably a list (possibly of l

Re: [R] Batch importing data

2012-04-27 Thread R. Michael Weylandt
list.files() will give you all the file names in your working directory (you can also give it a pattern argument) then can loop over those with something like: lapply(list.files(), read.table) which will put all your files in a list object. This is generally considered much more convenient than t

Re: [R] Min , Max

2012-04-27 Thread Jonsson
The piece of R code given above is meant to perform calculations for many files(12) in one folder.But I am getting this error:Error: subscript out of bounds.It finished reading the first file(successfully) but the error arose when it started to read the next file. Any suggestions why?. I think the

Re: [R] find the eigenvector corresponding to the largest eigenvalue

2012-04-27 Thread Berend Hasselman
On 27-04-2012, at 17:41, Rebecca wrote: > Hi, > If I use the eigen() function to find the eigenvalues of a matrix, how can I > find the eigenvector corresponding to the largest eigen value? What does the documentation of eigen() say in the Value section for values? Sorted in decreasing order.

[R] Error in .Call("X" ... X not in DLLS for package G

2012-04-27 Thread stat curio
Hello, I'm calling function X as .Call("X",a,b,PACKAGE="G") the function X has been registered as R_CallMethodDef callMethods [] = { {"X",(DL_FUNC) myfun,2}, {NULL, NULL, 0} }; ... R_registerRoutines(info, NULL, callMethods, NULL, NULL); yet, I (sometimes, not all the time) get this error:

Re: [R] Min , Max

2012-04-27 Thread Rui Barradas
Hello, Jonsson wrote > > Hellow everyone, > This code bellow will calculate average daily wind speed(measurements are > taken every three hours).Any ideas how to take the Min and Max instead of > average. > > library(Matrix) > setwd("C:\\Users\\aalyaari\\Desktop\\img") > listfile<-dir() > long

[R] find the eigenvector corresponding to the largest eigenvalue

2012-04-27 Thread Rebecca
Hi, If I use the eigen() function to find the eigenvalues of a matrix, how can I find the eigenvector corresponding to the largest eigen value? Thanks! [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.c

[R] Package for endemic channels in epidemiology

2012-04-27 Thread rafitoariaz
Does anybody knows if there is a special R package for making endemic channels graphics in epidemiology? Thanks -- View this message in context: http://r.789695.n4.nabble.com/Package-for-endemic-channels-in-epidemiology-tp4593029p4593029.html Sent from the R help mailing list archive at Nabble.co

Re: [R] To make a graph for 4 functions

2012-04-27 Thread Rui Barradas
Hello, quantum wrote > > lets say I have these function and I want to have a graph on them > > y0=x^2 > y1=x^3 > > Then I say this > > x=seq(0,10,length.out=100) > plot(x,y0,y1,type="l") > > but R does not give me a graph. How would you do it? > First of all, try your own code: > y0=x^2 E

Re: [R] Rconsole file fails to remember GUI settings, and script window text colour option is missing

2012-04-27 Thread geotheory
Hi there, its Windows 7 (32 bit) platform. Yes, I used R Studio when I started learning, but now prefer the simpler basic GUI. Maybe I'll have to go back to it, although that would seem like such a pointlessly ridiculous defeat by poor GUI design! -- View this message in context: http://r.78969

[R] multivariate xts merge question

2012-04-27 Thread Soo Sun Park
Hi, I have an xts starting with a number of columns (currency pairs see below), then I add new ones which are derived from existing ones (like adding the moving average of a column) by merging the new columns one by one. These get the name of the column they are calculated from concatenated with "

[R] To make a graph for 4 functions

2012-04-27 Thread quantum
lets say I have these function and I want to have a graph on them y0=x^2 y1=x^3 Then I say this x=seq(0,10,length.out=100) plot(x,y0,y1,type="l") but R does not give me a graph. How would you do it? -- View this message in context: http://r.789695.n4.nabble.com/To-make-a-graph-for-4-functions

[R] Batch importing data

2012-04-27 Thread jiangxijixzy
I want to import data from about 2000 text files, and hope to create a data frame to make it easy to quote the data. For example, the files like this Oil_20030801.txt, Oil_20030804.txt, Oil_20030805.txt … Oil_20120427.txt The dates aren’t continuous. I want to create the data frame called “Oil”, li

Re: [R] comparison of bivariate normal distributions

2012-04-27 Thread Fabian Roger
Hello Petr and thanks for your help! Thanks also for the correction on the code, of cause it is better to use the real mean and covariance than those estimated by mean() and cov(). What I am after is that if I have the two two-dimensional probability density functions of the distribution of my

[R] expression() and font.lab ?

2012-04-27 Thread aparna15
Hi.. I managed to use expression() for superscripting and subscripting values in my axis labels. However, I notice that the font and style that I had passed through par() are ignored. I used : par(font.lab=2, font=2, family="sans") but when I employ expression() for my xlab, the styling given a

Re: [R] HoltWinters() fitted values

2012-04-27 Thread slipkid90515
Yeah, I was pretty sure that it needed one period to begin estimating, but it just seemed odd to me that the plot function was able to interpolate all the way back to the beginning (well, nearly the beginning), but the fitted values only began after the first period. Thanks for your response! Jess

Re: [R] How to display data values for points in a plot?

2012-04-27 Thread daltieri
See ?text Hope it works for you. -- View this message in context: http://r.789695.n4.nabble.com/How-to-display-data-values-for-points-in-a-plot-tp2197796p4592822.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org m

Re: [R] Min , Max

2012-04-27 Thread R. Michael Weylandt
You might want to look into the caTools package: it provides runmean, runmin, and runmax functions -- if you set those for a window of length 8 and then take every 8th element, you should get what you're looking for (much cleaner and faster too!) A good way to do that subset is something like: x <

Re: [R] Min , Max

2012-04-27 Thread Jonsson
Dear Rui, I really appreciate your help. This is exactly what I was looking for.I know there is simpler way than mine but I couldn't figure it out.So, many many thanks. I wonder what is the difference between This:tm[ta[i],tb[i]]= round(mean(D[(d-1)*8 + 1:8, i])) and This: (Why not use t

Re: [R] check if excel file is

2012-04-27 Thread Duncan Murdoch
On 27/04/2012 12:08 PM, Ben quant wrote: Hello again, I'd like to determine if an Excel file is open or writable. Can anyone help me with that? Try to write to it. If you fail, it wasn't writable. (You can wrap your attempt in try() so that it doesn't abort your program.) If you're not read

Re: [R] check if excel file is

2012-04-27 Thread Ben quant
To get around the issue below, I just wrapped it with try(), but would like to know how to know the question below. Thanks! ben On Fri, Apr 27, 2012 at 10:13 AM, Ben quant wrote: > Forgot this: the solution doesn't have to come from the xlsx package... > > thanks > > ben > > > On Fri, Apr 27,

Re: [R] Memoize and vectorize a custom function

2012-04-27 Thread Henrik Bengtsson
On Thu, Apr 26, 2012 at 3:21 PM, Kamil Slowikowski wrote: > My goal is simple: calcuate GC content of each sequence in a list of > nucleotide > sequences. I have figured out how to vectorize, but all my attempts at > memoization failed. > > Can you show me how to properly memoize my function? > >

Re: [R] check if excel file is

2012-04-27 Thread Ben quant
Forgot this: the solution doesn't have to come from the xlsx package... thanks ben On Fri, Apr 27, 2012 at 10:08 AM, Ben quant wrote: > Hello again, > > I'd like to determine if an Excel file is open or writable. Can anyone > help me with that? > > I write some stats to an .xlsx Excel file usi

Re: [R] Merge function - Return NON matches

2012-04-27 Thread RHelpPlease
Hi again, Petr, your solution worked! Thanks everyone for your input. I'll look more into "setdiff." Cheers! -- View this message in context: http://r.789695.n4.nabble.com/Merge-function-Return-NON-matches-tp4590755p4593101.html Sent from the R help mailing list archive at Nabble.com. ___

[R] check if excel file is

2012-04-27 Thread Ben quant
Hello again, I'd like to determine if an Excel file is open or writable. Can anyone help me with that? I write some stats to an .xlsx Excel file using the xlsx package. I can't write to the file unless its closed. How do I determine if the .xlsx file is open or closed so I can write to it? I've

[R] Min , Max

2012-04-27 Thread Jonsson
Hellow everyone, This code bellow will calculate average daily wind speed(measurements are taken every three hours).Any ideas how to take the Min and Max instead of average. library(Matrix) setwd("C:\\Users\\aalyaari\\Desktop\\img") listfile<-dir() long <- file("C:\\Users\\aalyaari\\Desktop\\New f

Re: [R] Merge function - Return NON matches

2012-04-27 Thread Petr PIKAL
Hi If you used shorter names for your objects you will get probably more readable advice Is this what you wanted? truncated_dataframe[truncated_dataframe$CLAIM_NO %in% setdiff(truncated_dataframe$CLAIM_NO, truncated_list$CLAIM_NO),] Regards Petr > Hi there, > I've tried the noted solutions

Re: [R] get plot axis rounding method

2012-04-27 Thread Sarah Goslee
The help for axis() talks about it some, and provides the suggestion to see ?pretty - since you're not looking for a regular sequence of numbers, you may need to dig into the code itself. Or something in ?axis may offer the clue you need. But surely it's more appropriate to use the correct number

Re: [R] Merge function - Return NON matches

2012-04-27 Thread RHelpPlease
Hi there, I've tried the noted solutions: "If you do `no <- unlist(hrc_78_clm_no`, do you get a character vector of claim numbers you want to exclude? If so, then `subset(whatever, !CLAIM_NO %in% no)` should work." I converted the CLAIM_NO list to a character, with > hrc78_clmno_char <- format

Re: [R] get plot axis rounding method

2012-04-27 Thread Duncan Murdoch
On 27/04/2012 10:55 AM, Ben quant wrote: Hello, Does anyone know how to get the rounding method used for the axis tick numbers/values in plot()? I'm using mtext() to plot the values used to plot vertical and horizontal lines (using abline()) and I'd like these vertical and horizontal line value

[R] get plot axis rounding method

2012-04-27 Thread Ben quant
Hello, Does anyone know how to get the rounding method used for the axis tick numbers/values in plot()? I'm using mtext() to plot the values used to plot vertical and horizontal lines (using abline()) and I'd like these vertical and horizontal line values to be rounded like the axis tick values a

Re: [R] Rconsole file fails to remember GUI settings, and script

2012-04-27 Thread Duncan Murdoch
On 27/04/2012 9:58 AM, Petr PIKAL wrote: Hi Isn't possible just to change values in etc/Rconsole file? ## Colours for console and pager(s) # (see rw/etc/rgb.txt for the known colours). background = White normaltext = NavyBlue usertext = Red highlight = DarkRed You can customise it and keep

[R] R: PLM package PGGLS strange behavior

2012-04-27 Thread Millo Giovanni
Hello again. This is really strange: I actually get the right numbers all the time. I tried now and got > data("EmplUK", package="plm") > zz <- pggls(log(emp)~log(wage)+log(capital),data=EmplUK, model="random") Warning message: 'random' argument to pggls() has been renamed as 'pooling' > summa

Re: [R] PLM package PGGLS strange behavior

2012-04-27 Thread Ruben de Bliek
Thank you Millo. I was a little confused by the random versus pooling nomenclature used in PLM, thank you for clearing that up. I still have the issue of not receiving the proper coefficient estimates for the example in the paper though. My output is posted below; the estimates are substantially di

[R] PLM package PGGLS strange behavior

2012-04-27 Thread Millo Giovanni
Hello. No "strange behaviour" here, just a warning. There is a difference between an "error" and a "warning", and between an argument and a model. In this specific case, the warning is just there to remind you that, as stated, 'the "random" **argument** has been renamed to "pooling" ' (emphasis mi

Re: [R] Rconsole file fails to remember GUI settings, and script

2012-04-27 Thread Petr PIKAL
Hi Isn't possible just to change values in etc/Rconsole file? ## Colours for console and pager(s) # (see rw/etc/rgb.txt for the known colours). background = White normaltext = NavyBlue usertext = Red highlight = DarkRed You can customise it and keep your setting somewhere. With each new ins

Re: [R] Rconsole file fails to remember GUI settings, and script

2012-04-27 Thread R. Michael Weylandt
Sorry, I don't use Windows... can't help there. It's customary to keep cc'ing the list on these sorts of things so someone with a more similar platform/ more expertise can take the issue up if needed. Maybe someone else will be able to help you out. Michael On Fri, Apr 27, 2012 at 9:05 AM, geo t

Re: [R] Unable to compile & install rggobi

2012-04-27 Thread Indrajit Sengupta
I am able to compile it. However, when I try to check it - there is error:   D:\DPF\Rggobi\rggobi>R CMD check "D:\\Work\\tmp\\rggobi_2.1.17.tar.gz" * using log directory 'D:/Work/tmp/rggobi.Rcheck' * using R version 2.15.0 (2012-03-30) * using platform: i386-pc-mingw32 (32-bit) * using session char

Re: [R] Lambert (1992) simulation

2012-04-27 Thread Christopher Desjardins
On Fri, Apr 27, 2012 at 1:53 AM, Achim Zeileis wrote: > On Thu, 26 Apr 2012, Christopher Desjardins wrote: > > Hi, >> I am trying to replicate Lambert (1992)'s simulation with zero-inflated >> Poisson models. The citation is here: >> >> @article{lambert1992zero, >> Author = {Lambert, D.}, >> Jour

Re: [R] Rconsole file fails to remember GUI settings, and script window text colour option is missing

2012-04-27 Thread R. Michael Weylandt
The GUI's are OS specific -- which is yours? You might also want to check out RStudio -- also open source -- which provides a very nice cross-platform IDE: http://rstudio.org/ There are nice coloration options (both customizable and by default) -- I quite like the cobalt theme Michael On Fri, A

[R] Rconsole file fails to remember GUI settings, and script window text colour option is missing

2012-04-27 Thread geotheory
Am encountering two related problems since the 2.15 release. Apologies in advance for a mundane non code-related post, but you know how it is. I'm using the basic R GUI. 1: I use a black environment for no glare, so pre-version 2.15 I've had black backgrounds and white text. Since the 2.15 rele

Re: [R] HoltWinters() fitted values

2012-04-27 Thread R. Michael Weylandt
HoltWinters doesn't give fitted values for the entire time series since, like most time series models, there's a "recursive" element to it. I.e., if a very simple model is X_t = 1/2*(X_{t-1} + X_{t-2}) + epsilon, you need to take X_0, X_1 as is to "start" the series. If you run example(HoltWinters

Re: [R] Unable to compile & install rggobi

2012-04-27 Thread Indrajit Sengupta
I am sorry, but I didn't understand what you are trying to say here. Can you be a bit more explicit?   Indrajit   From: Prof Brian Ripley Cc: R Help Sent: Friday, April 27, 2012 2:21 PM Subject: Re: [R] Unable to compile & install rggobi You need to set som

Re: [R] random effects in library mgcv

2012-04-27 Thread Mabille, Geraldine
Thanks Simon...it's always clearer when you say it!!! Geraldine -Original Message- From: Simon Wood [mailto:s.w...@bath.ac.uk] Sent: 27. april 2012 12:41 To: Mabille, Geraldine Cc: r-help@r-project.org Subject: Re: [R] random effects in library mgcv Geraldine, I think that you are inter

Re: [R] creating a package?

2012-04-27 Thread R. Michael Weylandt
Do you want to create a function or something like a function or a package? Creating a function is easy: doAThing <- function(a, b, c){ print("The cow jumped over the moon") return(a + b^c) } Something like a function is somewhat ambiguous. To create a package, start with the package.sk

  1   2   >