Hi,
I would also like to point out that you flipped the first two the
values of theta in the R vs. FORTRAN versions. This fixes part of
your differences (and makes it easy to see that the differences occur
when j < i, as David and Mario point out).
Josh
On Sun, Aug 29, 2010 at 10:27 PM, Nam Let
On 30/08/2010 1:58 p.m., Derek M Jones wrote:
All,
I have been trying to get calls to hist(...) to be plotted
with the y-axis having a log scale.
I have tried: par(ylog=TRUE)
I have also looked at the histogram package.
Suggestions welcome.
You appear to be looking for a log-histogram func
When j==1 for loops from i down to zero. 5:0 is valid and means c(5,4,3,2,1,0)
Hope it helps
mario
Nam Lethanh wrote:
> Dear Guys,
>
> I do converting codes from Fortran into R and got stuck in solving LOOPING
> procedure with R. In FORTRAN, it is (DO and END DO) for loopi
On Aug 30, 2010, at 1:27 AM, Nam Lethanh wrote:
Dear Guys,
I do converting codes from Fortran into R and got stuck in solving
LOOPING
procedure with R. In FORTRAN, it is (DO and END DO) for looping in
the net.
In R, it is (FOR with { }).
Looking at the results (namely the 1's from t
What statistical measure(s) tend to be answering ALL(?) question of practical
interest?
--
View this message in context:
http://r.789695.n4.nabble.com/Re-Question-regarding-significance-of-a-covariate-in-a-coxme-survival-tp2399386p2399577.html
Sent from the R help mailing list archive at Nabbl
On Aug 29, 2010, at 8:47 PM, Lorenzo Cattarino wrote:
Hi,
I have the following matrix
cc <- matrix (1:21, 3)
cc[,3:4]<- 0
cc
[,1] [,2] [,3] [,4] [,5] [,6] [,7]
[1,]1400 13 16 19
[2,]2500 14 17 20
[3,]3600 15 18 21
On Aug 30, 2010, at 12:18 AM, Yong Wang wrote:
Dear list
I used to use python or awk do preliminary process and then feed into
R. In some circumstances, the data transmission becomes quite a pain.
I am wondering if there is a convenient way to read in R text file
(not data, text file in common
On Sun, Aug 29, 2010 at 9:18 PM, Yong Wang wrote:
> Dear list
>
> I used to use python or awk do preliminary process and then feed into
> R. In some circumstances, the data transmission becomes quite a pain.
> I am wondering if there is a convenient way to read in R text file
> (not data, text fil
Dear Guys,
I do converting codes from Fortran into R and got stuck in solving LOOPING
procedure with R. In FORTRAN, it is (DO and END DO) for looping in the net.
In R, it is (FOR with { }).
I believe there is something wrong with my coding in R, do hope that you can
help me solving following pr
Hi,
I believe what you are looking for is in the "teststat" slot
sjd.v...@teststat
sjd.v...@teststat[1] # first one
etc.
HTH,
Josh
On Sun, Aug 29, 2010 at 9:12 PM, aurumor wrote:
>
> Hi all, I am working on exporting "Johansen test statistics" (Johansen test:
> "ca.jo" in package "urca")to E
Dear list
I used to use python or awk do preliminary process and then feed into
R. In some circumstances, the data transmission becomes quite a pain.
I am wondering if there is a convenient way to read in R text file
(not data, text file in common sense) and specify field separator and
records sep
What statistical measure(s) tend to be answering ALL(?) question of practical
interest?
--
View this message in context:
http://r.789695.n4.nabble.com/Re-Question-regarding-significance-of-a-covariate-in-a-coxme-survival-tp2399386p2399524.html
Sent from the R help mailing list archive at Nabb
On Aug 30, 2010, at 12:57 AM, David Winsemius wrote:
On Aug 29, 2010, at 10:50 PM, Erik Ramberg wrote:
I'm a newbie to R and I was hoping someone could answer a simple
question. I want to read in an ASCII file with 3 columns - x,y,z.
Let's say there is a lot of data - 100,000 entries.
Hi,
I have the following matrix
cc <- matrix (1:21, 3)
cc[,3:4]<- 0
cc
[,1] [,2] [,3] [,4] [,5] [,6] [,7]
[1,]1400 13 16 19
[2,]2500 14 17 20
[3,]3600 15 18 21
and I would like to sum just the values in columns
Hi all, I am working on exporting "Johansen test statistics" (Johansen test:
"ca.jo" in package "urca")to Excel. The problem is that the function output
is not a number, but like this:
#
# Johansen-Procedure Unit Root / Cointegration Test #
##
On Aug 29, 2010, at 10:50 PM, Erik Ramberg wrote:
I'm a newbie to R and I was hoping someone could answer a simple
question. I want to read in an ASCII file with 3 columns - x,y,z.
Let's say there is a lot of data - 100,000 entries. I then want to
histogram x values that pass arbitrary
Hi Marcel,
Not quite sure what you want the while loop for. Does this do what you want?
mydat <- read.table(textConnection("
Pair group param1
1 D 10
1 D 10
1 R 10
1 D 10
2 D 10
2
Eh?
## First calculate the means:
mns <- with(alldata, tapply(param1, list(Pair, group), mean))
## now put the results into a data frame
res <- data.frame(mns, dif = mns[, "D"] - mns[, "R"])
## Then write it out if that's your thing.
-Original Message-
From: r-help-boun...@r-projec
Hi Guys,
stumped by a simple problem. I would like to take a file of the form
Pair group param1
1 D 10
1 D 10
1 R 10
1 D 10
2 D 10
2 D 10
2 D 10
2
I'm a newbie to R and I was hoping someone could answer a simple question. I
want to read in an ASCII file with 3 columns - x,y,z. Let's say there is a lot
of data - 100,000 entries. I then want to histogram x values that pass
arbitrary (and complicated) cuts on y and/or z. Likewise, I want
Hi Derek,
Here is an option using the package ggplot2:
library(ggplot2)
x <- sample(x = 10:50, size = 50, replace = TRUE)
qplot(x = x, geom = "histogram") + scale_y_log()
However, the log scale is often inappropriate for histograms, because
the y-axis represents counts, which could potentially b
Hello
all,
Is
there a complete list of Sweave tags (control sequences) and their usage? For
instance,
I know a few blow. But I donât really know how to use them. It seems to me
that
there is nowhere to find further information. I would really appreciate any
input. Thanks!
Heyi
Â
The
fe
How about computing the log of you variable and calling hist() on the log data.
logy <- log(y)
Hhist(logy)
John
John Sorkin
Chief Biostatistics and Informatics
Univ. of Maryland School of Medicine
Division of Gerontology and Geriatric Medicine
jsor...@grecc.umaryland.edu
-Original Message
All,
I have been trying to get calls to hist(...) to be plotted
with the y-axis having a log scale.
I have tried: par(ylog=TRUE)
I have also looked at the histogram package.
Suggestions welcome.
--
Derek M. Jones tel: +44 (0) 1252 520 667
Knowledge Software Ltd
On Aug 26, 2010, at 7:10 PM, Peter Dunn wrote:
Hi all
I was playing with termplot(), and came across what appears to be an
inconsistency.
It would appreciate if someone could enlighten me:
# First, generate some data:
y <- rnorm(100)
x <- runif(length(y),1,2)
# Now find the log of x:
Hi,
On Aug 29, 2010, at 8:00 PM, Worik R wrote:
> Is there a simple way to put a legend outside the plot area for a
> simple
> plot?
>
> I found... (at http://www.harding.edu/fmccown/R/)
>
> # Expand right side of clipping rect to make room for the legend
> *par(xpd=T, mar=par()$mar+c(0,0,0,4)
I'm trying to run an epsilon regression model, and am comparing the results
between e1071 and kernlab. I believe that I'm calling the ksvm and svm
functions the same way but I'm getting different results:
library(e1071); library(kernlab)
ksvm(x=1:100, y=(1:100)/5, type="eps-svr", kpar=list(sigma=
Is there a simple way to put a legend outside the plot area for a simple
plot?
I found... (at http://www.harding.edu/fmccown/R/)
# Expand right side of clipping rect to make room for the legend
*par(xpd=T, mar=par()$mar+c(0,0,0,4))*
# Graph autos (transposing the matrix) using heat colors,
# pu
CRAN (and crantastic) updates this week
New packages
* ProjectTemplate (0.1-2)
Maintainer: John Myles White
Author(s): John Myles White
http://crantastic.org/packages/ProjectTemplate
The ProjectTemplate package provides a function, create.project(),
that automatically buil
Hi
>the two models are identical because of having the same independent
> variable and dependent variable.they produce different termplot()s because
> of they base on different variables,one is x,the other is logx.see the
> lateral axis.
Sure; this is all obvious from the code and the plots.
Using a p-value to make any kind of decision is questionable to begin
with, and especially unreliable in choosing covariates in regression.
Old studies, e.g. by Walls and Weeks and by Bendel and Afifi, have shown
that if predictive ability is the criterion of interest and one wishes
to use p-values
On Aug 29, 2010, at 3:42 PM, sam.e wrote:
Hello everyone,
I have been trying to figure out away to integrate under a spline
produced
by the package tps(fields). As the package does not output functions
I am
trying to do something similar to the trapezium rule. My data are 3D
(x, y &
z)
On Sun, Aug 29, 2010 at 1:13 PM, Abhisek wrote:
> Hi there,
>
> Ive tried trawling the lists for a solution but I could not find any
> matches. I am typing up all my code on a Linux machine and I call this
> other script file from my script file using source("foo.r"). Now sometimes
> i access my
On Aug 29, 2010, at 3:13 PM, moleps wrote:
glm(A~B+C+D+E+F,family = binomial(link =
"logit"),data=tre,na.action=na.omit)
Error in `contrasts<-`(`*tmp*`, value = "contr.treatment") :
contrasts can be applied only to factors with 2 or more levels
however,
glm(A~B+C+D+E,family = binomial(li
On Aug 29, 2010, at 12:46 PM, Tal Galili wrote:
Hello all.
A Journal we are sending an article to is asking for the following:
To ensure the best reproduction quality of your figures we would
appreciate
high resolution files. All figures should preferably be in TIFF or EPS
format... and sh
Hi Tal,
You have set the resolution, but you have not set the width/height.
The res argument generally controls how many pixels per inch (PPI
which is often used similarly to DPI). So if you want 800 DPI and you
want it to be a 4 x 4 inch graph something like:
tiff(file = "temp.tiff", width = 32
glm(A~B+C+D+E+F,family = binomial(link = "logit"),data=tre,na.action=na.omit)
Error in `contrasts<-`(`*tmp*`, value = "contr.treatment") :
contrasts can be applied only to factors with 2 or more levels
however,
glm(A~B+C+D+E,family = binomial(link = "logit"),data=tre,na.action=na.omit)
runs
Hello everyone,
I have been trying to figure out away to integrate under a spline produced
by the package tps(fields). As the package does not output functions I am
trying to do something similar to the trapezium rule. My data are 3D (x, y &
z). I have extracted from the surface output by Tps the
On Sun, Aug 29, 2010 at 5:46 PM, Tal Galili wrote:
> Hello all.
>
> A Journal we are sending an article to is asking for the following:
>
> To ensure the best reproduction quality of your figures we would appreciate
> high resolution files. All figures should preferably be in TIFF or EPS
> format
Hi there,
Ive tried trawling the lists for a solution but I could not find any
matches. I am typing up all my code on a Linux machine and I call this
other script file from my script file using source("foo.r"). Now sometimes
i access my folder from my Windows machine at work (the files are on
dr
Hey!
Just a quick question:
How do you interpret cross-validation error?
For my model the function cv.glm returns a cross validation error of 0.31
does this mean to say that model has an accuracy of 0.69
(69 Percent of points are correctly classified)?
Thanks,
Mark
--
View this message i
Hello all.
A Journal we are sending an article to is asking for the following:
To ensure the best reproduction quality of your figures we would appreciate
high resolution files. All figures should preferably be in TIFF or EPS
format... and should have the following resolution: Graph: 800 - 1200
On Aug 28, 2010, at 10:58 PM, Randklev, Charles wrote:
Hi,
I am trying to assemble a three-way contingency table examining the
presence/absence of mussels, water depth (Depth1 and Depth 2) and
water velocity (Flow vs. No Flow). I have written the following code
listed below; however, whe
check at the online help file of function ?names(), and then try this:
names(list.a)
I hope it helps.
Best,
Dimitris
On 8/29/2010 5:51 PM, Hyunchul Kim wrote:
Hi, all
I want to take a vector of component names of a list.
list.a<- list('x'=1, 'y'=2)
how to get a c('x','y') from list.a?
T
Hy,
I had a mistake on a function of a package i have created!
I have solved it and then i repackaged and installed the modified package.
I use to launch R from Excel!
And so when i launch R, and next call my function from the workspace, i
still find the problem on my function.
And when i read on
Try this:
names(list.a)
On Sun, Aug 29, 2010 at 12:51 PM, Hyunchul Kim
wrote:
> Hi, all
>
> I want to take a vector of component names of a list.
>
> list.a <- list('x'=1, 'y'=2)
>
> how to get a c('x','y') from list.a?
>
> Thanks in advance,
>
> Hyunchul
>
>[[alternative HTML version de
Hi, all
I want to take a vector of component names of a list.
list.a <- list('x'=1, 'y'=2)
how to get a c('x','y') from list.a?
Thanks in advance,
Hyunchul
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https://st
Take a look on ?basename help page.
On Sun, Aug 29, 2010 at 12:07 PM, Hyunchul Kim
wrote:
> Hi, all
>
> I made a simple R script to take the basename of a file without directory
> names.
>
> path.splitted <- strsplit('/path/to/a_basename', '/')
> path.length <- length(path.splitted[[1]])
> basena
Hi, all
I made a simple R script to take the basename of a file without directory
names.
path.splitted <- strsplit('/path/to/a_basename', '/')
path.length <- length(path.splitted[[1]])
basename <- path.splitted[[1]][path.length] # basename <- 'a_basename'
Is there a simple function for this?
so
My suggestion for Teresa:
If compare model 1 and model 2 with model 0 respectively, the (penalized)
likelihood ratio test is valid.
IF you compare model 2 with model 3, the (penalized) likelihood ratio test
is invalid. You may want to use AIC/SBC to make a subjective decision.
--
View this
My suggestion:
If compare model 1 and model 2 with model 0 respectively, the (penalized)
likelihood ratio test is valid.
IF you compare model 2 with model 3, the (penalized) likelihood ratio test
is invalid. You may want to use AIC/SBC to make a subjective decision.
--
View this message in con
I didn't see any error when I ran your code in my computer:
> numbers <- c(1134,956,328,529,435,599,27,99)
> dim(numbers) <- c(2,2,2)
> numbers
, , 1
[,1] [,2]
[1,] 1134 328
[2,] 956 529
, , 2
[,1] [,2]
[1,] 435 27
[2,] 599 99
> dimnames(numbers)[[3]] <-list("Mussels", "
The likelihood ratio test is more reliable when one model is nested in the
other. This true for your case.
AIC/SBC are usually used when two models are in a hiearchical structure.
Please also note that any decision made
made based on AIC/SBC scores are very subjective since no sampling
distributio
The likelihood ratio test is more reliable when one model is nested in the
other. This true for your case.
AIC/SBC are usually used when two models are in a hiearchical structure.
Please also note that any decision made made based on AIC/SBC scores are
very subjective since no sampling distributi
Try this:
format(data$start, "%Y")
On Sun, Aug 29, 2010 at 11:32 AM, André de Boer wrote:
> Hi,
>
> Sorry for this simple question but I searched the internet and can't find
> the answer.
>
> >From a date I want the year extracted:
> > data$start[1
> [1] "2006-11-01"
>
> Thanks for the answer,
Hi,
Sorry for this simple question but I searched the internet and can't find
the answer.
>From a date I want the year extracted:
> data$start[1
[1] "2006-11-01"
Thanks for the answer,
Andre
[[alternative HTML version deleted]]
__
R-help@r-pr
Hi,
Your example works fine for me. My guess is that you have one of wd,
wv, MP, or Count defined as a global variable. This is the main reason
the use of attach() is discouraged by many people on this list. The
safer thing to do is
model1 <- glm(Count~MP+wd+wv,poisson. data = frame)
-Ista
On Sat
Hi David,
Thanks for your advice.
B.R.
Stephen L
- Original Message
From: David Winsemius
To: Stephen Liu
Cc: "r-help@r-project.org"
Sent: Sun, August 29, 2010 1:52:50 AM
Subject: Re: [R] About plot graphs
On Aug 28, 2010, at 9:15 AM, Stephen Liu wrote:
> Hi Gavin,
>
> Lot of t
Hi Greg,
Thanks for your advice.
> data(women)
> women
height weight
1 58115
2 59117
3 60120
4 61123
5 62126
6 63129
7 64132
8 65135
9 66139
10 67142
11 68146
12 69150
13 70154
14
Try this:
> x
startdate enddate
1 27SEP2005 01JAN2006
> x$start <- as.Date(x$startdate, format="%d%b%Y")
> x$end <- as.Date(x$enddate, format="%d%b%Y")
> x
startdate enddate startend
1 27SEP2005 01JAN2006 2005-09-27 2006-01-01
> x$duration <- x$end - x$start
> x
startdate
Hi,
I have a data.frame with factors in columns like
startdate enddate
27SEP2005 01JAN2006
How can I calculate the duration between those two dates and move this in a
extra column in the data.frame.
Thanks,
André
[[alternative HTML version deleted]]
__
[[alternative HTML version deleted]]
__
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-c
https://stat.ethz.ch/mailman/listinfo/r-help
At the bottom of the webpage.
-c
On 08/29/2010 03:58 AM, Kaigang Li wrote:
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-he
[[alternative HTML version deleted]]
__
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-co
64 matches
Mail list logo