Hi,
I'm trying to import categorical data from SPSS to R using the script:
xxx -spss.get(xxx.por, use.value.labels=TRUE) but unfortunately am getting
an error message 'error reading portable-file dictionary'.
I have successfully imported data in the past.
What could be the problem with this
Dear all,
my R files (and the .csv files as well) are saved somewhere pretty
deep down my hard disk.
i have to chage to working directory therefore everytime i run R (i
run it on powerPC mac), which is disgusting.
using the setwd command at the beginning of an R script doesnt really
help
When the error occurs, valueDiff is NA:
Error in if ((seedCount = seedNumber) (valueDiff sup)) { :
missing value where TRUE/FALSE needed
valueDiff
[1] NA
Look at your loop; you are going through 100 times so on the last time
you are trying to access: fcsPar[k+1] which is the 101th entry
It may be disgusting, but I'm not how you expect R to know where to startup.
On my Mac, I keep all my scripts in a per-project working directory.
I therefore type
cd ~/Documents/ataxia
If you have multiple nested directories then why not create a
directory alias (soft-link) so it is easy to cd
Thanks folks fo all the help.
i just missed the part where to set the initial starting directory. i
´ll try Rprofile.
thanks so much
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
I think I should have posted this question here as well. I am posting my
question here since it is R related. Please see below. I originally posted
this to sci.stat.math
Nasser Abbasi [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
I think R documentation is a bit hard for me to
David Winsemius wrote:
I have a variable which is roughly age categories in decades. In the
original data, it came in coded:
str(xxx)
'data.frame': 58271 obs. of 29 variables:
$ issuecat : Factor w/ 5 levels 0 - 39,40 - 49,..: 1 1 1 1...
snip
I then defined issuecat as ordered:
Hi,
Maybe I have not been looking in the right spot, but, I have not been
able to fine a command to automatically calculate the running
cumulative sum of a vector. Is there such a command?
Example of current code:
eig$values
[1] 678.365651 6.769697 2.853783
Simo Vundla wrote:
Hi,
I'm trying to import categorical data from SPSS to R using the script:
xxx -spss.get(xxx.por, use.value.labels=TRUE) but unfortunately am getting
an error message 'error reading portable-file dictionary'.
I have successfully imported data in the past.
What could
Keith, are you looking for 'cumsum' ?
Gabor
On Sat, Jan 05, 2008 at 08:32:41AM -0600, Keith Jones wrote:
Hi,
Maybe I have not been looking in the right spot, but, I have not been
able to fine a command to automatically calculate the running
cumulative sum of a vector. Is there such a
On Jan 5, 2008 8:32 AM, Keith Jones [EMAIL PROTECTED] wrote:
Hi,
Maybe I have not been looking in the right spot, but, I have not been
able to fine a command to automatically calculate the running
cumulative sum of a vector. Is there such a command?
Try
help.search(cumulative sum)
Hadley
On 06/01/2008 9:36 AM, Nasser Abbasi wrote:
I think I should have posted this question here as well. I am posting my
question here since it is R related. Please see below. I originally posted
this to sci.stat.math
Nasser Abbasi [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Thank you, Dr Ripley. After some false starts and consulting MASS2,
ChambersHastie and the help files, this worked acceptably.
xxx$issuecat2-C(xxx$issuecat2,poly,1)
attr(xxx$issuecat2,contrasts)
.L
0-39 -6.324555e-01
40-49 -3.162278e-01
50-59 -3.287978e-17
60-69
Dear r-helpers,
Can one save a dynamic graphic produced by rgl, e.g.:
open3d(); x - sort(rnorm(1000)); y - rnorm(1000); z -
rnorm(1000) + atan2(x,y); plot3d(x, y, z, col=rainbow(1000), size=2)
as a dynamic figure that can be embedded in a pdf?
_
Professor
Hello
I tried to use the CSVSource in the TextDocCol function in the tm package. But
a) data from several columns is concatenated in one entry and
b) data in a large text column is broken into several entries
I hoped that it would be possible to assign columns as metadata to one
entry with one
Hi,
you might try to use the foreign-package, which contains the function
read.spss. This works fine most of the time,
For a description of its usage, see the help-files or my own website:
http://www.rensenieuwenhuis.nl/r-project/manual/basics/getting-data-
into-r-2/
Remember, you'll need
In R factanal output, I can't find a function to give me residuals e.
I mannually got it by using x -lamda1*f1 -lamda2*f2 - ... -lamdan*fn, but the e
I got are not uncorrelated with all the f's.
What did I do wrong? Please help.
Yijun
Hi,
you may want to use that apply / tapply function. Some find it a bit
hard to grasp at first, but it will help you many times in many
situations when you get the hang of it.
Maybe you can get some information on my site: http://
www.rensenieuwenhuis.nl/r-project/manual/basics/tables/
On Sun, 6 Jan 2008, Rense Nieuwenhuis wrote:
Hi,
you might try to use the foreign-package, which contains the function
read.spss. This works fine most of the time,
For a description of its usage, see the help-files or my own website:
?rgl.snapshot
Michael Kubovy wrote:
Dear r-helpers,
Can one save a dynamic graphic produced by rgl, e.g.:
open3d(); x - sort(rnorm(1000)); y - rnorm(1000); z -
rnorm(1000) + atan2(x,y); plot3d(x, y, z, col=rainbow(1000), size=2)
as a dynamic figure that can be embedded in a
On Sun, 6 Jan 2008, Yijun Zhao wrote:
In R factanal output, I can't find a function to give me residuals e.
I mannually got it by using x -lamda1*f1 -lamda2*f2 - ... -lamdan*fn, but
the e
I got are not uncorrelated with all the f's.
What did I do wrong? Please help.
What did you use for
Hi,
I just discovered decompose() and stl(), both are very nice! I am wondering
if R also has a function that calculates the seasonal index, or make the
seasonal adjustment directly using the results generated from either
decompose() or stl(). It seems that there should be one, but I couldn't
On Wednesday 26 December 2007 04:14, Kunio takezawa wrote:
R-users
E-mail: r-help@r-project.org
My understanding is that package mgcv is based on
Generalized Additive Models: An Introduction with R (by Simon N. Wood).
On the page 126 of this book, eq(3.4) looks a quartic equation with
I have not tried this but once you know where the
(relatively permanent)working directory is then
putting setwd(my.directory) in your R.profile should
work'
--- bunny , lautloscrew.com [EMAIL PROTECTED]
wrote:
Dear all,
my R files (and the .csv files as well) are saved
somewhere pretty
On Thursday 03 January 2008 13:54, Prof Brian Ripley wrote:
fit1 - glm(factor(x1)~factor(Round)+x2,family=binomial(link=probit))
fit2 - gam(factor(x1)~factor(Round)+x2,family=binomial(link=probit))
all.equal(fitted(fit1), fitted(fit2))
[1] TRUE
so the fits to the data are the same: your
The factanal was called with 'varimax' rotation. The factors scores are
uncorrelated. But
the residuals I got by using
X - sum(loadings*factors-scores) is not uncorrelated to the factor scores.
I thought the residuals should be independent to the factor scores as ?factanal
says:
On 06/01/2008 10:46 AM, Michael Kubovy wrote:
Dear r-helpers,
Can one save a dynamic graphic produced by rgl, e.g.:
open3d(); x - sort(rnorm(1000)); y - rnorm(1000); z -
rnorm(1000) + atan2(x,y); plot3d(x, y, z, col=rainbow(1000), size=2)
as a dynamic figure that can be embedded
On Jan 4, 2008 6:21 PM, Andrea Previtali [EMAIL PROTECTED] wrote:
Sorry, I realized that somehow the message got truncated. Here is the
remaining part of the SAS output:
Solutions for Fixed Effects:
Effect DIST DW ELI SEX SEAS Estimate Std. Error
DF t Value Pr
Hi,
I have a ts object with a frequency of 4, i.e., quarterly data, and I would
like to calculate the mean for each quarter. So for example:
ts.data=ts(1:20,start=c(1984,2),frequency=4)
ts.data
Qtr1 Qtr2 Qtr3 Qtr4
1984 123
19854567
198689 10 11
On Jan 6, 2008 5:17 PM, tom soyer [EMAIL PROTECTED] wrote:
Hi,
I have a ts object with a frequency of 4, i.e., quarterly data, and I would
like to calculate the mean for each quarter. So for example:
ts.data=ts(1:20,start=c(1984,2),frequency=4)
ts.data
Qtr1 Qtr2 Qtr3 Qtr4
1984
p.s. I tried to use both regression and Bartlett way to get the scores. In
both
cases, the scores are uncorrelated, but the errors are NOT uncorrelated to the
scores,
and are also NOT uncorrelated among themselves.
What am I missing? factanal() are supposed to give independent errors vectors,
Thanks Gabor!!
On 1/6/08, Gabor Grothendieck [EMAIL PROTECTED] wrote:
On Jan 6, 2008 5:17 PM, tom soyer [EMAIL PROTECTED] wrote:
Hi,
I have a ts object with a frequency of 4, i.e., quarterly data, and I
would
like to calculate the mean for each quarter. So for example:
Hi,
I'm Roslina, PhD student of University of South Australia, Australia
from school Maths and Stats. I use S-Plus before and now has started
using R-package. I used
to analyse rainfall data using julian date. Is there any similar
function that you can suggest to me to be used in R-package?
Dear all,
I am performing a binomial glmm analysis using the lmer function in
the lme4 package (last release, just downloaded). I am using the
Laplace method.
However, I am not sure about what I should do to test for the
significance of fixed effects in the binomial case: Is it correct to
Dear All,
I am trying to solve the following maximization problem with R:
find x(t) (continuous) that maximizes the
integral of x(t) with t from 0 to 1,
subject to the constraints
dx/dt = u,
|u| = 1,
x(0) = x(1) = 0.
The analytical solution can be obtained easily, but I am trying to
Rosalina,
You should start by reading the Posting Guide - it has helpful advice on
how to solve a problem yourself and how to craft postings to get good
answers.
The Posting Guide says:
[some basics deleted]
Do your homework before posting: If it is clear that you have done basic
useR's,
I would like to know if there is a way to avoid using FOR loops to perform
the below calculation.
Consider the following data:
x
[,1] [,2] [,3]
[1,]4 111
[2,]192
[3,]733
[4,]364
[5,]685
xk
Var1 Var2 Var3
1 -0.25
On 06/01/2008 7:55 PM, Paul Smith wrote:
On Jan 7, 2008 12:18 AM, Duncan Murdoch [EMAIL PROTECTED] wrote:
I am trying to solve the following maximization problem with R:
find x(t) (continuous) that maximizes the
integral of x(t) with t from 0 to 1,
subject to the constraints
dx/dt = u,
On Jan 6, 2008, at 7:55 PM, dxc13 wrote:
useR's,
I would like to know if there is a way to avoid using FOR loops to
perform
the below calculation.
Consider the following data:
snip
Here, X is a matrix of 3 variables in which each is of size 5 and
XK are
some values that correspond
On Jan 7, 2008 1:04 AM, Duncan Murdoch [EMAIL PROTECTED] wrote:
I am trying to solve the following maximization problem with R:
find x(t) (continuous) that maximizes the
integral of x(t) with t from 0 to 1,
subject to the constraints
dx/dt = u,
|u| = 1,
x(0) = x(1) = 0.
This can be discretized to a linear programming problem
so you can solve it with the lpSolve package. Suppose
we have x0, x1, x2, ..., xn. Our objective (up to a
multiple which does not matter) is:
Maximize: x1 + ... + xn
which is subject to the constraints:
-1/n = x1 - x0 = 1/n
-1/n = x2 -
There are a number of different ways that you would have to manipulate
your data to do what you want. It is useful to learn some of these
techniques. Here, I think, are the set of actions that you want to
do.
x - read.table(textConnection(row k.idx step.forwd pt.nummodel
prev
On Jan 7, 2008 1:32 AM, Gabor Grothendieck [EMAIL PROTECTED] wrote:
This can be discretized to a linear programming problem
so you can solve it with the lpSolve package. Suppose
we have x0, x1, x2, ..., xn. Our objective (up to a
multiple which does not matter) is:
Maximize: x1 + ... + xn
I followed the instructions at
http://cran.r-project.org/bin/linux/ubuntu/README.html, but I'm
getting the following error:
~: sudo apt-get install r-base
Reading package lists... Done
Building dependency tree... Done
Some packages could not be installed. This may mean that you have
requested an
Hi,
I'm Roslina, PhD student of University of South Australia, Australia
from school Maths and Stats. I use S-Plus before and now has started
using R-package. I used
to analyse rainfall data using julian date. Is there any similar
function that you can suggest to me to be used in R-package?
Hello
I'm using rainbow function to generate 10 colors for the plot and it is
difficult to tell the neighboring colors from each other. How can I make
the colors more differently.
Thanks
Zhaoming
[[alternative HTML version deleted]]
__
Specify them exactly if there are only 10.
On Jan 6, 2008 10:55 PM, Wang, Zhaoming (NIH/NCI) [C]
[EMAIL PROTECTED] wrote:
Hello
I'm using rainbow function to generate 10 colors for the plot and it is
difficult to tell the neighboring colors from each other. How can I make
the colors more
Dear R People:
Hao Yu has a very nice package for mpi in R.
I'm trying to experiment on my own and am looking at
building a shared library with objects from mpicc.
I tried to compile a .o object and then use R CMD SHLIB to
compile the shared library.
But I'm getting errors with the MPI_Init
Dear All,
I've successfully import my synteny data to R by using scan command. Below
show my results. My major problem with my data is how am i going to combine the
column names with the data( splt) where i have tried on cbind but a warning
message occur. I have realized that the splt
49 matches
Mail list logo