Hi!
I have a need to do the ridiculous and run a batch file if certain
conditions are met within an R script. is there a simple way to do so? or
to run dos commands?
Thanks!
Daniel
[[alternative HTML version deleted]]
__
R-help@r-project.org
[i]=summary(lm(y~(x>(i-1$r.squared
tested.threshold[i]=i-1
}
#inspect r-squareds
print(data.frame(tested.threshold,r.squared))
#Should indicate the highest r-squared
#at the appropriate threshold level
HTH,
Daniel
-
cunc
any ideas?
Also is there a way of including the threshold in the actual model, so
that could be estimated too?
Thanks
Dan
--
**
Daniel Brewer, Ph.D.
Institute of Cancer Research
Molecular Carcinogenesis
Email: daniel.bre...@icr.ac
x=0.01345778543577
signif(x,3)
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von Gundala Viswanath
Gesendet: Tuesday, September 08, 2
If you are looking for a function to standardize a variable so that it has
mean zero and unit variance:
std=function(x){if(length(which(is.na(x)))==0) (x-mean(x))/sd(x) else
(x-mean(x,na.rm=T))/sd(x,na.rm=T)
}
x=rnorm(100,3,5)
mean(x)
sd(x)
x2=std(x)
mean(x2)
sd(x2)
HTH,
Daniel
del with interaction effects if not all
direct effects are included. And in fact, I never see this done in analyses
in my field (business/economics).
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: John
hen compare 2 to 1, and 3 to 2. This tells you whether including more
variables (hierarchically) makes your model better.
HTH,
Daniel
On a different note, if lme fits with "restricted maximum likelihood," I
think I remember that you cannot compare them. You have to fit them with
&quo
The workers=as.factor(workers) codeline in my post dropped below my name. It
should be in the code before the command line for the linear model.
Daniel Malter wrote:
>
> Wen, to follow up on Thierry, your workers are nested in machines (since
> each worker only works one machine).
are
equal for both machines
#the equivalent formulation used is: is the sum of the coefficients across
machines equal to zero?
library(car)
linear.hypothesis(fm4,hypothesis.matrix=c(1,1,1,-1,-1,-1),rhs=c(0))
hope that helps,
daniel
workers=as.factor(workers)
Wen Huang-3 wrote:
>
> Hello,
ation of nested effects in R (e.g. with the nlme and lme4
libraries). So go ahead and put in the effort.
Daniel
ps: on a more general note, the R-help list is to help with the
implementation in R rather than statistical/econometric questions,
especially if these problems are exte
that the approach to use OLS to model your data is
fine if your error distribution (the distribution of e in the simulated
data) is normal.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mai
asks the question how much does
group=2 with sub=b stand out from the average in its group and in its sub.
To clarify your confusion, you may want to write out the model formula.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht
and five cities.
Age=rep(0:3,each=25)
City=rep(0:4,20)
e=rnorm(100)
#Create a dependent variable
Height=(Age-1)+(City-1)+(Age-1)*(City-1)+e
#Box whisker plot of Height by Age category for each City
bwplot(Height~factor(Age)|factor(City))
Daniel
-
cuncta stricte
I updated the previously posted function for Cramer's V so that it
automatically prints Cramer's V, chi-square, the degrees of freedom, and the
significance level of Cramer's V based on the chi-square value and the
degrees of freedom with desired (user-supplied) levels of precision. An
example is
cb[[2]][rep(1:nrow(cb[[2]]), nrow(cb[[1]])), ] )
##compare m.o with all x.o where rows and columns of x.o with tied
totals are permuted##
for(i in 1:nrow(rperm)){
for(j in 1:nrow(cperm)){
if(identical(m.o,x.o[rperm[i,],cperm[j,]])) {
cat('TRUE','\n')
break
}
> -Original Message-
> From: Marc Schwartz [mailto:marc_schwa...@me.com]
> Sent: Monday, August 24, 2009 9:57 AM
> To: Daniel Nordlund
> Cc: r help
> Subject: Re: [R] Combining matrices
>
>
> On Aug 24, 2009, at 11:46 AM, Marc Schwartz wrote:
>
> &
;1&z<3000)
sum(z>3000)
It's unclear to me whether you want to summarize the other variables (x and
y) for each of the categories of z. If you want to do that, use tapply (see
?tapply).
Daniel
-
cuncta stricte discussurus
-
ortant, they are given
so as to illustrate how I want to combine the matrices. I.e., I am looking for
a general way to combine the first row of x with each row of y, then the second
row of x with y,
Thanks,
Dan
Daniel Nordlund
Bothell, WA USA
Than
Thank you, William.
Best,
Daniel
William Revelle wrote:
>
> At 6:15 PM -0400 8/21/09, Daniel Malter wrote:
>>I have a quick statistical question and hoped somebody has a tip for me
>>without me having to go to the local statistician on Monday.
>>
>>I assess 4 sta
se an alternative procedure given that my responses are ordinal.
I am grateful for your tips,
Daniel
---
"Who has visions should see a doctor,"
Helmut Schmidt, German Chancellor (1974-1982).
__
R-help@r-proj
Assuming your data.frame has the name "data," you would extract arbitrary
row n by
data[n, ]
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-proje
ncorrelated with the Xs, which is unlikely due to
the correlation of kidc and year). The nice thing about it is that the year
fixed effects model is unbiased in your case and spares you from including
polynomials for the year.
HTH,
Daniel
ps: If you want to model survival, you may want to think abo
given the vague description
of your data.
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von Jack Su
Gesendet: Friday, August 14, 2009
index")
##Perform multiplication
names(new.x2)
new.x2$"1"=new.x2$"1"*new.x2$"value"
##Reshape new.x2 back to the initial wide format of the matrix
new.x2=new.x2[,1:3]
new.x=reshape(new.x2,idvar="index",ids=row.names(x),direction="wide",times=
Once you have the long format of the dataset, you could just code a "bin"
variable and merge with this bin variable instead. Piece o' cake, ain't it?
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
V
y="index")
##Perform multiplication
names(new.x2)
new.x2$"1"=new.x2$"1"*new.x2$"value"
##Reshape new.x2 back to the initial wide format of the matrix
new.x2=new.x2[,1:3]
new.x=reshape(new.x2,idvar="index",ids=row.names(x),direction="wide",
any) is not linear.
For a comparison of all groups against one another from an analysis of
variance, I think there other methods, like the Bonferroni-Dunn test (as a
post-hoc test).
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche
draw one unlucky seed, but that
indeed setting different seeds aims at assuring "better randomness," as you
suggest.
Best,
Daniel
Chang, C-Y. wrote:
>
> Greetings,
>
> When reading the random forest manual by Liaw, in the examples
> "set.seed" is always
equality sign)! Rather choose something like y.good, y.better,
y.best, or whatever you like as variable names.
HTH,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...
build models that you can
understand and interpret.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von SNN
Gesendet: Wednesday, August 12, 2009
variables as factors/dummies
(or even factors coded as polynomial orthogonal contrasts), which is another
reason to pick up a book on the topic.
HTH,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-projec
x=c("blah","blub","bleep","foo")
y=rnorm(4)
yourdata=data.frame(x,y)
yourdata
newdata=yourdata[order(y),]
newdata
thisiswhatyouwant=newdata[1:2,]
thisiswhatyouwant
hth,
daniel
-
cuncta stricte discussurus
---
foo <- c("blue", "red", "green")
foo=as.factor(foo)
foo=as.numeric(as.character(foo))
foo
#the numeric ordering is alphabetic
hth,
daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-hel
Hi you can use newvariable=as.numeric(variablename). This converts your
factors into numeric variables, but not always with the desired result. So
make sure that you check whether "newvariable" gives you what you want.
Otherwise recoding by hand is indicated.
Best,
Daniel
Noah S
ed using just those 3 numbers (the first
3 numbers in the first column of your matrix) and recycled them as needed to
fill out the matrix.
You probably should have create the data frame directly, something like
df <- data.frame(rbind(a,b,d,e))
As for question 2, I don't know why you got the
> -Original Message-
> From: r-help-boun...@r-project.org
> [mailto:r-help-boun...@r-project.org] On Behalf Of Daniel Nordlund
> Sent: Friday, August 07, 2009 2:50 PM
> To: r-help@r-project.org
> Subject: Re: [R] Seeing negative numbers to zero
>
> > -Ori
you say it doesn't work, what does that mean? Do you get an error
message? Are you left with negative numbers? What? A minimal,
self-contained, reproducible example would help us help you.
> KN1 <- rnorm(100)
> KN2 <- ifelse(KN1 < 0, 0, KN1)
Works fine for fine for me.
D
vector it gets
coerced to the more general type, in this case, numeric.
Note that "is.numeric" returns TRUE for both is.numeric(0) and
is.numeric(0L).
Daniel Gerlanc
Associate Analyst
Geode Capital Management
1 Post Office Sq, Floor 28
Boston, MA 02109
daniel.gerl...@geodecapital.com
___
't the quartz(family="Times-Roman") make the fonts change?
(2) Is it possible to use any MacOS system fonts with R and the Quartz
device window?
Best regards,
Daniel Farrell
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mai
wever, without a self-contained example, it is
impossible for us to know whether the error lies here or in one of the many
other reasons (e.g. on of the functions called in your MODELS function).
Daniel
-
cuncta stricte discussurus
-
-Ursprüng
and I may quote David Winsemius at this point: "In general this falls into
the category of a request to "read my mind".
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mai
e posting guide. And no worries, I
have asked questions like yours before. It just takes some willingness and
effort to learn to ask better questions in order to get helpful answers.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht
Either you use
for (k%in%col)
or
for (k in min(col):max(col))
does that work for you?
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag
Not knowing the package or the function. Could the round() function help
you? Or do you mean decimals shown in a plot?
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help
ot;D" "E" NA
> is.na(s2)
[1] FALSE FALSE FALSE FALSE FALSE TRUE
>
Notice that in string s, the characters (NA) are surrounded by quotes, and R
returns false for is.na(). But for string s2, the missing value NA is not
surrounded by quotes and is.na() returns TRUE for s2[6
[1] 19
# but I am looking for the unevaluated expression (".Last.expression",
so to say), which would be expression(x * x + 3) in this case
Daniel
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read th
Hi Everyone,
is there the possibility in R to assign a variable to be an alias of
another one?
Example:
x <- 17
# assign y to be an alias of x
y # returns 17
x <- 4
y # returns 4
Daniel
__
R-help@r-project.org mailing list
https://stat.e
does "length" instead of "nlevels" do what you want to do?
with(Trees,tapply(SppID,PlotID,unique))
daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-b
Caio, check the lme4 library. The lmer function allows for fixed and random
effects.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von
Look up the McNemar test. That sounds right...
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von mik07
Gesendet: Tuesday, July 28, 2009
)))-1)))
}
}
}
Daniel Malter wrote:
>
> You can copy the code below to your R-code editor. For Yule's Q, the data
> is expected in two vectors. For cramer's phi, the data is expected in
> separate columns of a matrix or dataframe.
>
> ##Run this code
> yule.Q=function(x,y){(table
I should have mentioned that I am using the lmer library for my analyses,
just in case other methods provide results differently.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r
rather than an R question, but I thought one of the
many specialists in experiments might be able to help me out quickly on this
or point me to appropriate literature.
Thanks,
Daniel
---
"Who has visions should see a doctor,"
Helmut Schmi
?
> x<-c(rnorm(100), 30);
> boxplot(x)
> boxplot(x,outline=FALSE)
Dan
Daniel Nordlund
Bothell, WA USA
__
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 commented, minimal, self-contained, reproducible code.
al variation
among the subject (in other words, respecting that some are just more likely
than others to answer yes).
But Robert has pointed out many valuable alternative approaches.
Best,
Daniel
-
cuncta stricte discussurus
-
_
V
ns
par(mfcol=c(1,2))
hist(estim[,1],main="Intercept")
hist(estim[,2],main="Effect of variable 'test'")
HTH,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [m
Here it is...
http://www.nabble.com/plotting-confidence-intervals-td24482119.html
Marc's answer is probably the way to go
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: Daniel Malter [mailto:dan...@um
I recently answered this (or, rather, basically the same) question in a
thread with an example in it. I am trying to find it back.
Just a sec
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto
vents variable given your conditions
does that work for you?
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von jimdare
Gesendet: Thursday, J
x4)
listdata=list(data1,data2)
for(i in 1:length(listdata)){
listdata[[i]][,length(listdata[[i]])+1]=listdata[[i]][,length(listdata[[i]])
]*listdata[[i]][,length(listdata[[i]])-1]
}
HTH,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche N
is multiple
imputation, plotting n imputations at alpha = 1/n to see where there is, or is
not, variability.)
Many thanks,
Daniel Farewell
Cardiff University
R version 2.9.1 (2009-06-26)
i386-apple-darwin8.11.1
locale:
en_GB.UTF-8/en_GB.UTF-8/C/C/en_GB.UTF-8/en_GB.UTF-8
attached base package
XYZ=XYZ[XYZ$A==TRUE , ] should do. Note that this specific command
overwrites your XYZ dataframe. If you want to keep XYZ, you will want to
name the newly created frame differently.
HTH,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche
prediction.
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von Rbeginner
Gesendet: Monday, July 20, 2009 10:50 PM
An: r-help@r
asets...
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von Rbeginner
Gesendet: Sunday, July 19, 2009 9:49 PM
An: r-help@r-project.org
Betreff: [
F$d) * DF$Test + (DF$c+DF$d) * !DF$Test
>
> DF$f = with(DF, (c*d)*Test + (c+d)*!Test)
>
> DF
Mark,
Why can't you use ifelse() ?
DF$g <- with(DF, ifelse(Test,c*d,c+d))
Have I missed something in what you are doing?
Dan
Daniel Nordlund
Bothell, WA USA
__
I appreciate the info!
I am mostly interested with ML missing data imputation. Is there
another R module which has such a function that is well regarded?
Thank you.
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEAS
Hello,
I apologize if an answer to my questions is available, or if I
submitted this question incorrectly. I have read the mailing lists, as
well as the R Project and CRAN homepages. However, I may have missed
something.
I noticed the package 'norm' has been removed. Its page
http://cran.r-projec
It is because the nesting structure perfectly explains the data (i.e., there
is only one observation and, therefore, no variation for each Ind in each
Treatment).
e=rnorm(90,0,1)
x=rep(1:3,30)
y=rep(1:30,each=3)
z=x+y+e
ano=aov(z~factor(y)/factor(x))
ano
residuals(ano)
Best,
Daniel
Bump
Anyone?
Thanks
Daniel
On 13 jul 2009, at 10.57, Daniel Klevebring wrote:
> Dear all,
>
> I am using package.skeleton to build a small packages of misc function
> for personal use. I have recently discovered that the option
> force=TRUE doesn't seem to do what is mean
example
should be fine.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von Erin Hodgess
Gesendet: Tuesday, July 14, 2009 11:40 AM
An: R help
y
#pch=16 puts a filled dot
#lcolor=NA removes the dotted lines on the chart
#now plot the confidence intervals
for(i in 1:max(CI$index)){
lines(c(CI$lower[i],CI$upper[i]),c(i,i))
}
#for each index (i.e., estimated coefficient)
#plot x-coordinates CI$upper and CI$lower
#at y-coordinate = in
ed in the ABOVE diagonal elements (i.e. not
including diagonal element temselves), the your loop should be
for (i in 1:9)
{
for (j in (i+1):10)
{
// do something
}
}
And you avoid your current problem.
Hope this is helpful,
Dan
Daniel Nordlund
Bothell, WA USA
__
folder or
the dk folder altogether, the changes come along so to me it seems
that it's the overwrite part that doesn't work as it should - or am I
doing something wrong here? To me, it seems that the function
safe.dir.create (which is defined in package.skeleton never overwrit
do that until I learn what I'm doing wrong.
>
> I've got more interesting questions of which the answers are far more
> important to me than this one!
>
> Thanks,
> Mark
Mark,
Take a look at the readline() function.
Hope this is helpful,
Dan
Daniel Nordlund
Bothell,
put another condition in your loop
if(all.equal(x,y)=TRUE) i=i+1 else t.test...
something in that direction.
best,
daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun
TRUE, density = NULL, angle = 0,
col = c("yellow","Blue","orange"), border = par("fg"),
main = "Mujeres",
xlim =NULL, ylim = NULL, xpd = TRUE, log = "",
axisnames = FALSE,
axis(1,cex.axis=0.75))
That s
folder or
the dk folder altogether, the changes come along so to me it seems
that it's the overwrite part that doesn't work as it should - or am I
doing something wrong here?
See below for sessionInfo.
Thanks a bunch
Daniel
> sessionInfo()
R version 2.9.0 (2009-04-17)
i
Can you provide a self-contained example of what you did so far (i.e. code
for simulating some data and code for the plot)? That would greatly help to
help you find a solution.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht
have you tried the pyramid function in the epicalc package?
best,
daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von Victor Manuel Garcia
return a list of the
values
multipleoutput<-function(x)
{
squared<-x^2
cubed<-x^3
exponential<-exp(x)
factorialVal<-factorial(x)
return(list(squared=squared, cubed=cubed, exponential=exponential,
factorialVal=factorialVal))
}
Hope this is he
the read.xls() function from the gdata package to get
the file, something like this
library(gdata)
df <- read.xls("http://mirecords.umn.edu/miRecords/download_data.php?v=1";)
Hope this is helpful,
Dan
Daniel Nordlund
Bothell, WA USA
__
An Econometrician may help you with more theoretical insights, but you could
do Monte-Carlo simulations of data and analyze the effects you are
interested in.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun
26.00 10,274.00 10,326.00 10,390.00 10,570.00
> >> 10,638.00 10,728.00 10,952.00 9,854.00
> >>>
> >>
> >> Now, here's the confusion. plot(T1[,1],T1[,10]) creates a plot, but
> >> the range on both X & Y is 1-10. I want 1-10 on the X axis but ne
tween x1 and
x2, and with a level 1 random effect (intercept) only? That would give a
hint where the singularity arises.
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help
identical. If they are, the results
should be the same.
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: Cecilia Carmo [mailto:cecilia.ca...@ua.pt]
Gesendet: Wednesday, June 24, 2009 1:17 PM
An: Daniel Malter
Betreff: Re: AW
~x,subset=year%in%c(1),data=newdata).
If you still observe differences, you have to be more specific and provide
your data and code...
Hope that helps,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r
it doesn't.
Thanks
Dan
--
******
Daniel Brewer, Ph.D.
Institute of Cancer Research
Molecular Carcinogenesis
Email: daniel.bre...@icr.ac.uk
**
The Institute of Cancer
Hi,
I have found the stable 64bit OS X leopard builds here:
http://r.research.att.com/
Dan
--
**
Daniel Brewer, Ph.D.
Institute of Cancer Research
Molecular Carcinogenesis
Email: daniel.bre...@icr.ac.uk
Hello,
I am after a stable 64 bit binary of R for OS X Leopard (i.e. 2.8).
There seems to be the siggestion that thery should be available from CRAN:
"leopardBinaries of universal (32-bit and 64-bit) package builds for
Mac OS X 10.5 or higher"
But when I follow the link there is only a co
der in MEAN2 and SD2
LAC2=rep(1:5,each=4)
DIM2=rep(1:4,5)
#plot
#may require to install package Hmisc
library(Hmisc)
Dotplot(LAC2~Cbind(MEAN2,INT.minus,INT.plus)|DIM2,method="bars")
hth
Daniel
-
cuncta stricte discussurus
-
-Ursprüngli
s:
data$SOCIAL_STATUS<-ifelse(data$SOCIAL_STATUS=="B" & data$MALE>4, "C",
data$SOCIAL_STATUS)
Right?
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-bo
min(which(is.na(inc)==FALSE)) #index
inc[min(which(is.na(inc)==FALSE))] #value
hth
daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im
Auftrag von
question which random effects to select is a modeling
question and thus ultimately the ressearchers responsibility.
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
Von: r-help-boun...@r-project.org [mailto:r-help-boun
function(x,y){(table(x,y)[1,1]*table(x,y)[2,2]-table(x,y)[1,2]*table(
x,y)[2,1])/(table(x,y)[1,1]*table(x,y)[2,2]+table(x,y)[1,2]*table(x,y)[2,1])
}
yule.Q(ycat,xcat)
Best,
Daniel
-
cuncta stricte discussurus
-
-Ursprüngliche Nachricht-
V
- it's superb! but I need call a function: wy[i]<-
> ifelse(((is.na(a))), call_fun1(x), call_fun2(x)
>
>
>
Not sure if I understand everything you want to do, but what is wrong with just
using
wy <- ifelse(is.na(a), fun1(x), fun2(x))
Hope this
for each day
tapply(y,day,mean)
##shows mean of y for each day
##should be about equal to two times the day index no.
tapply(y,day,sd)
##show sd of y for each day
##should be about equal to the day index no.
Best,
Daniel
-
cuncta stricte discussurus
[2,1,2] #slope 2
summary(reg)$coef[3,1,2] #slope 3
summary(reg)$coef[1,2,1] #SE intercept 1
summary(reg)$coef[2,2,1] #SE intercept 2
summary(reg)$coef[3,2,1] #SE intercept 3
summary(reg)$coef[1,2,2] #SE slope 1
summary(reg)$coef[1,2,2] #SE slope 2
summary(reg)$coef[1,2,2] #SE slope 3
#etc.
Best
hello,
i was trying to predict values for a garch, so i did:
predict(fitgarch,n.ahead = 20)
but this doesn't work. Someone can tell me how to get the 20 values ahead of a
garch model.
thanks in advance
_
Obtenh
hello,
i was trying to predict values for a garch, so i did:
predict(fitgarch,n.ahead = 20)
but this doesn't work. Someone can tell me how to get the 20 values ahead of a
garch model.
thanks in advance
_
O Windows
Hello,
I need to know how to import ARIMA coefficients. I already determined the
coefficients of the model with other software, but now i need to do the
forecast in R.
For Example: I have a time series named x
and i have fitted an ARIMA(1,0,1) (with other software)
AR coef = -.17
801 - 900 of 1303 matches
Mail list logo