Displaying 20 results from an estimated 6000 matches similar to: "Data packages in R V 1.3.1 in Win2K"
2003 Feb 28
2
lattice and fitted function error
Platform: WIN2000
Version of R: 1.6.2
I'm interested in plotting fitted values in a trellis xyplot. I believe the
following should work; however, I only get the points (not the fitted
lines).
library(lattice)
trellis.device(bg="white")
xyplot(MULTDV~TIME|SUBNUM,data=TEMP,
panel=function(x,y){
panel.xyplot(x,y)
lines(x,fitted(lm(y~poly(x,1),na.action=na.omit)))
2003 Apr 09
3
Reading in multiple files
I apologize if this is a FAQ -- I kind of recall seeing something along
these lines before, but I couldn't find the message when I searched the
archives.
Problem:
1. I have hundreds of small files in a subdirectory ("c:\\temp") and I would
like to combine the files into a single data frame.
2. Individually, it is easy to read each file
2002 Oct 08
2
Orthogonal Polynomials
Looking to the wonderful statistical advice that this group can offer.
In behavioral science applications of stats, we are often introduced to
coefficients for orthogonal polynomials that are nice integers. For
instance, Kirk's experimental design book presents the following
coefficients for p=4:
Linear -3 -1 1 3
Quadratic 1 -1 -1 1
Cubic -1 3 -3 1
In R orthogonal
2002 Oct 09
1
Summary Orthogonal Polynomials
As usual, the R newsgroup set me straight (thanks to Douglas Bates, Robert
Balshaw and Albyn Jones).
There is really no difference between using orthogonal polynomials of the
form:
Linear -3 -1 1 3
Quadratic 1 -1 -1 1
Cubic -1 3 -3 1
Versus
> poly(c(1:4),3)
1 2 3
[1,] -0.6708204 0.5 -0.2236068
[2,] -0.2236068 -0.5 0.6708204
[3,] 0.2236068
2002 Nov 21
0
Analysis of Data with Observation Weights Revisited
In lm and glm, the weights command should only be used when the variances of
the observations are inversely proportional to the weights.
Recently, however, a question came up regarding how one could estimate lm
and glm models with weights where the weights refer to number of
observations (counts).
Because lm and glm do not handle this case, SE values will be wrong if one
uses the weight command
2003 Mar 03
0
lm, gee and lme
Behavioral science data is often collected from nested structures (students
in schools, in districts, etc.). This can produce nonindependence among
responses from individuals in the same groups. Consequently, researchers
are advised to model the nested nature of the data to avoid biases in SE
estimates.
Failing to account for nonindependence can lead to SE estimates that are too
large or too
2003 Feb 01
1
matrix subscripts in replacement
I'm reluctant to draw the S-PLUS and R comparison (these are different
programs after all), but could someone tell me why the following matrix
substitution works in S-PLUS, but not R. I'm curious because matrix
substitution is a really slick way to "cleaning up" columns of data in data
frames. For example, in the following I change values of 1 to values of 10,
but only for
2002 May 28
0
Lattice background color answer
It turns out that there is a color named "transparent" that does the trick
with the trellis device. Thanks to Brian Ripley for pointing it out.
trellis.device(bg="transparent")
My original post is below, but it boils down to "how can I make a trellis
graph that doesn't contain any background color?" This can be useful when
you paste graphics into documents
2005 Sep 27
1
Simulate phi-coefficient (correlation between dichotomous vars)
Newsgroup members,
I appreciate the help on this topic.
David Duffy provided a solution (below) that was quite helpful, and came
close to what I needed. It did a great job creating two vectors of
dichotomous variables with a known correlation (what I referred to as a
phi-coefficient).
My situation is a bit more complicated and I'm not sure it is easily
solved. The problem is that I must
2004 Sep 21
2
Bootstrap ICC estimate with nested data
I would appreciate some thoughts on using the bootstrap functions in the
library "bootstrap" to estimate confidence intervals of ICC values
calculated in lme.
In lme, the ICC is calculated as tau/(tau+sigma-squared). So, for instance
the ICC in the following example is 0.116:
> tmod<-lme(CINISMO~1,random=~1|IDGRUP,data=TDAT)
> VarCorr(tmod)
IDGRUP = pdLogChol(1)
2003 May 30
2
Extracting Vectors from Lists of Lists Produced by Functions
If you found my subject heading to be confusing then I'm sure you'll enjoy
the example I've included below. I find the apply type functions to be
wonderful for avoiding loops but when I use them with existing functions, I
end up using loops anyway to extract the vectors I want. I would appreciate
it if someone could show me how to avoid these loops. Thanks.
EXAMPLE:
2006 Jun 28
1
Simulate dichotomous correlation matrix
Newsgroup members,
Does anyone have a clever way to simulate a correlation matrix such that
each column contains dichotomous variables (0,1) and where each column
has different prevalence rates.
For instance, I would like to simulate the following correlation matrix:
> CORMAT[1:4,1:4]
PUREPT PTCUT2 PHQCUT2T ALCCUTT2
PUREPT 1.0000000 0.5141552 0.1913139 0.1917923
PTCUT2
2002 May 27
1
lattice background color
I'm sure there is a simple answer to this question, but it stumps me so far.
I've been using R to create graphic images and paste them into other
programs (Word, PowerPoint).
Recently, I've been using lattice (wonderful package), but I can't figure
out how to create graphs in lattice that don't have a background color --
that is, my graphs carry over the grey background if I
2008 Oct 03
1
question on xyplot
Hi List,
I have the following problem: I am using the multilevel package and make.univ function for available in the package and then xyplot from lattice and I want to know how could I be able to use the ?coefficient? for the straight line that passes the data ?
Example from help:
library(multilevel)
data(univbct) #a data set already in univariate or stacked form for job satisfaction
2004 Aug 19
3
List dimention labels to plots of components
It is frustrating to see the labels I want in the dimensions of a list but not be able to extract those labels into titles for plots generated from component objects. If someone could set me straight, I would appreciate it. For your amusement, I have provided an example of the Byzantine code I am currently using to avoid loops:
# Simulate ANOVA type test data
sex<-c(rep(1,8),rep(0,8))
2004 Jul 11
1
WinXP "developer" asks: Tcl/Tk (Rcmdr) under OS X?
It is my understanding that Tcl/Tk does not come with the base installation of R under OS X ( http://www.sciviews.org/_rgui/projects/TclTk.html). Is there a simple way to explain how a user with limited tolerance for computer complexity can obtain and install Tcl/Tk for OS X?
Thanks.
Chuck
Background: Roughly a third of my target audience uses OS X. I do not and I do not have access to a
2006 Feb 08
2
Compiling errors for Matrix_0.995-5.tar.gz under XP
I installed the MinGW-5.0.0 compilers today (gcc-3.4.2 is now contained in the 'Current' distribution. When the current compilers failed to compile the referenced Matrix update and not knowing how to check the exact version numbers for individual files, I applied the Id.exe and f771.exe fixes from the 'Building R for Windows' page (http://www.murdoch-sutherland.com/Rtools/#ldbug).
2004 Apr 19
1
Menu addditions to Rcmdr v0.9-6
1) In general, I would appreciate help in adding functions to the Rcmdr
menu system. I've been able to modify the menus themselves and source test
code but I can't get R functions to execute from the menu. My latest proof
of concept code follows:
Three lines added to "Rcmdr-menus.txt":
menu junkMenu topMenu "" ""
2001 Oct 24
0
Re: Compiling R v 1.3.1 under Irix 6.5 on SGI Origin
Hello Laurent, Ray and Greg,
I tried the gmake settings.
Yet, I still got an Error code 1 message when I run the test.
running regression tests
don't know how to make ../library/base/R/base (bu42).
*** Error code 1 (bu21)
Thanks you if you have any idea.
Manuel
-----Message d'origine-----
De : Laurent Gautier [ mailto:laurent at genome.cbs.dtu.dk
<mailto:laurent at
2003 Apr 17
0
Win2K v WINE
Hi All,
I found an old article on running WINE alongside Windows 2000
yesterday. It advocated using the command line of "wine --winver nt2k
[program name]", in the example "wine --winver nt2k mspaint.exe". I
tried this out with Paintshop Pro which WINE HQ says does run with WINE,
but had even less success than before. At least without using that extra
part I got an error