On Feb 15, 2013, at 9:26 PM, Janesh Devkota wrote:
Hi I am trying to find the relationship between two variables.
First I fitted a linear model between two variables and I found the
following results:
Residual standard error: 0.03253 on 2498 degrees of freedom
Multiple R-squared: 0.5551, Adjus
Folks,
I am having problems with a plot I want to create to give an impression
of changes in an ordinal scale measure (1-5) at three time points (0,
14 and 21 days). I can produce a radial plot of bare vectors but getting
this to appear on the base plot is not possible as it always seems to
On 15 February 2013 21:26, Janesh Devkota wrote:
> Hi I am trying to find the relationship between two variables.
>
> First I fitted a linear model between two variables and I found the
> following results:
> Residual standard error: 0.03253 on 2498 degrees of freedom
> Multiple R-squared: 0.5551
Hi I am trying to find the relationship between two variables.
First I fitted a linear model between two variables and I found the
following results:
Residual standard error: 0.03253 on 2498 degrees of freedom
Multiple R-squared: 0.5551, Adjusted R-squared: 0.5549
F-statistic: 3116 on 1 and 2498
Dear R People:
I'm using R2HTML but having a strange result.
Here is the original data:
resp trt block
90.3 A I
89.2 A II
98.2 A III
93.9 A IV
87.4 A V
97.9 A VI
92.5 B I
89.5 B II
90.6 B III
94.7 B IV
87.0 B V
95.8 B VI
85.5 C I
90.8 C II
89.6 C III
86.2 C IV
88.0 C V
93.4 C VI
82.5 D I
89.5 D
Hi:
See if the following works for you:
library(reshape2)
library(ggplot2)
tdm <- melt(testData)
ggplot(tdm, aes(x = Var2, y = Var1, fill = factor(value))) +
labs(x = "MHz", y = "Threshold", fill = "Value") +
geom_raster() +
scale_fill_manual(breaks = levels(factor(tdm$value)),
On 13-02-15 6:14 PM, Scott Robinson wrote:
I want to loop through slots of an S4 object and am unsure how to do so
since the only way I can find to access them is individually in the form
'object@slotName'. I have guessed at a few possibilities which did not work
and I have read some S4 object tu
look at dev.new() to specify plot window size
and then ?layout to specify number and size of each plot in the window
Jiaqi.Zhang wrote
> Hi, all,
>
> I am working on the following code to learn how to plot graphs together. I
> used the par(mfrow=c(1,3)) function to try to put all three plot()
HI Eliza,
Suppose you have 147 data files in the same working directory. Here, I am
using "Eliza1.txt" and a modified "Eliza2.txt" (attached).
list.files()
#[1] "Eliza1.txt" "Eliza2.txt"
lapply(list.files(),function(i) str_count(gsub(" $","",readLines(i))," "))
#count the spaces. Used gsub
I want to loop through slots of an S4 object and am unsure how to do so
since the only way I can find to access them is individually in the form
'object@slotName'. I have guessed at a few possibilities which did not work
and I have read some S4 object tutorials and things but still unsuccessful.
I
Hello All,
I am new to the list. I have been learning to use R recently and its been
great to see so much help available.
However I must admit, I have stumbled upon a problem with correlation
matrices and was hoping if someone could help.
I have an excel workbook with a sheet per drug.
Each shee
William,
> and here mention "intra-class name clashes" (I'm not sure what you
> mean by this).
sorry, i meant, in something like C++, if i have a class Foo and you
have a class Bar, then i can invent whatever method names/signatures i
want, independent of whatever method names/signatures *you* wa
Hi,
I couldn't find the data(manaus) in library(Kendall).
I guess data(GuelphP) is similar to your dataset.
class(GuelphP)
[1] "ts"
typeof(GuelphP)
#[1] "double"
head(GuelphP)
#[1] 0.47 0.51 0.35 0.19 0.33 NA
GuelphP
# Jan Feb Mar Apr May Jun Jul Aug Sep Oct
You were right,
the following two work
testData<-matrix(data=round(runif(25)),nrow=5,ncol=5,dimnames=list(Var1=c(1:5),Var2=c(1:5)))
ggplot(melt(testData), aes(Var2,Var1, fill=value))+xlab("MHz") +
ylab("Threshold") + geom_raster() + scale_fill_gradient(low="#FF",
high="#00")
stil
Hi Boris
Not sure what you mean exactly
try
library(latticeExtra)
useOuterStrips(dotplot(count ~ subject|risk*treatment,df))
if you want to change the order of the subjects in each panel and an
index column and plot the index column instead of subject and change
the scales to suit.
HTH
Dun
This is unfortunately reinforced by the "(Not So) Short Introduction
to S4 Object Oriented Programming in R" - I wouldn't recommend that
document to learn about S4.
The most important thing to get about OO in R is that methods belong
to generic functions, not like classes, as in most other program
TACC = Texas Advanced Computing Center, OS is Linux. I have used shell
commands for simple copy procedure. This time, I have to copy tens of
thousand files, and I can write an R code to find all of those files. I am
sure shell command can be used to get that done but I have almost no
knowledge of i
Good afternoon,
I would like to ask for help in controlling y-axis limits and labels in
lattice doplots. Unfortunately, the problem is somewhat convoluted,
please bear with the long explanation.
I would like to create a 3x3 lattice of dotplots, say subject ~ count.
The plot is conditioned on var
I thought you were thinking of the R class system (the S3 and S4 ones
anyway) as if it were C++'s. It is quite different.
Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com
> -Original Message-
> From: Greg Minshall [mailto:minsh...@umich.edu]
> Sent: Friday, February 15, 2013 1:37
This has basically nothing to do with R, so please don't post here.
You may wish to try the r-sig-mixed-models list, however. They are
more sympathetic to such questions -- and what are likely to be the
torrent from you that follows.
-- Bert
On Fri, Feb 15, 2013 at 9:17 AM, Bone, Jonathan
wrote
Compare:
persp(matrix(c(1,1,NA,NA,
1,1,NA,NA,
1,NA,NA,NA,
1,NA,NA,1), 4,4), zlim=c(0,2))
persp(matrix(c(1,1,0,0,
1,1,0,0,
1,0,0,0,
1,0,0,1), 4,4), zlim=c(0,2))
--
David.
On Feb 15, 2013,
On Feb 15, 2013, at 1:14 AM, jas wrote:
> Hello David,
> thanks again for your reply.
>
> Two things remain unclear. That the data is disjointed is ok, as there are
> only values in hectares, where there are actually buildings and stuff,
> forest/nature is NA.
>
> The presp-scan that I get fro
Dear all,
I am a new user to R and I am using pracma and nloptr libraries to minimize
a numerical integration subject to a single constraint . The integrand
itself is somehow a complicated function of x and y that is computed
through several steps. i formulated the integrand in a separate functi
Dear Eliza,
Try this:
Lines1<-readLines(textConnection("1911.01.01 7.87
1911.01.02 9.26
1911.01.03 8.06
1911.01.04 8.13
1911.01.05 12.90
1911.02.06 5.45
1911.02.07 3.26
1911.03.08 5.70
1911.03.09 9.24
1911.04.10 7.60
1911.05.11
I am trying to use the SeasonalMannKendall function in the Kendall package.
My dataset (alb_data) is in the same format as the example dataset
(manaus) in the package.
> class(manaus)
[1] "ts"
> is.ts(manaus)
[1] TRUE
> typeof(manaus)
[1] "double"
> alb_data=read.table("R:/albemarle_manken.tx
Please, help with a formula for dealing with unbalanced design:
To see the counts:
aggregate(dfa$CertId,by=list(type=dfa$ComType,stat=dfa$StatusCodeId),length)
type stat x
1C1 6571
2C3 28957
3C8 12390
4C 11 12415
5E 13 9
6R 1351
7E 15
HI,
No problem.
?c() for concatenate to vector or list().
If I use do.call(cbind,..) or do.call(rbind,...)
do.call(cbind,lapply(list.files(recursive=T)[grep("m11kk",list.files(recursive=T))],function(x)
{names(x)<-gsub("^(.*)\\/.*","\\1",x); lapply(x,function(y)
read.table(y,header=TRUE,stri
HI,
Just to add:
res<-do.call(c,lapply(list.files(recursive=T)[grep("m11kk",list.files(recursive=T))],function(x)
{names(x)<-gsub("^(.*)\\/.*","\\1",x); lapply(x,function(y)
read.table(y,header=TRUE,stringsAsFactors=FALSE,fill=TRUE))})) #it seems like
one of the rows of your file doesn't
Hi,
I am creating a mixed model based on a experiment where each subject has 2
repeats. In some instances though there is only data for one of a given
subjects repeats for most there is data for both. Can I still justify having
subject as a random effect?
Thanks,
Jonathan
[X]
[X]
[X]
[X]
[X]
Hi,
I will be performing mixed effects regression on subjects total scores from 2
player games (prisoners dilemma) that played. I am aware that including both
players score from a game will cause problems due to non-independence. Is there
a way that to deal with this apart from randomly picking
Due to missing data with some of my predictor variables I first do multiple
imputation as follows:
library(foreign)
library(Amelia)
library(norm)
set.seed(666)
M=10
impdat <-
NVP[,c("X_t0","X_t","nvp","adstatus","t0rwfa","ageatran","whostage","t0rhfa","vlsupp","t0rwfh","t0rvl","t0rcd4pc","postran
Hi,
#working directory data1 #changed name data to data1. Added some files in each
of sub directories a1, a2, etc.
indx1<- indx[indx!=""]
lapply(indx1,function(x) list.files(x))
#[[1]]
#[1] "a1.txt" "m11kk.txt"
#[[2]]
#[1] "a2.txt" "m11kk.txt"
#[[3]]
#[1] "a3.txt"
Earlier you wrote
> changing "me" to "b1" in A's bB(), allows A to use B's setGeneric()
and here mention "intra-class name clashes" (I'm not sure what you
mean by this).
In R, classes do not "own" (or contain) generic functions. They can supply
methods for generic functions but a generic function
Hello,
In what follows I've used print(), not system().
The trick is to use paste0() to form the command.
for (i in 1:10) {
cmd <- paste0('C:/Users/.../dssp-2.0.4-win32.exe -i ',
sprintf("data_%s.txt",i), ' -o ', sprintf("data_%s.dssp",i))
print(cmd)
}
Hope this helps,
Rui Barrada
I think what you want is something like this
system(sprintf('C:/Users/.../dssp-2.0.4-win32.exe -i data%d.txt -o
data%d.dssp', i, i))
On Fri, Feb 15, 2013 at 12:33 PM, Esam Tolba wrote:
> hi all
> I am using r (2.15.2) in windows 7 32bit
> I want to execute an external program from r console. th
hi all
I am using r (2.15.2) in windows 7 32bit
I want to execute an external program from r console. the program is a
command line program which needs the following format to start
C:/Users/.../dssp-2.0.4-win32.exe -i
data_1.txt -o data_1.dssp
I used the system co
Can anyone help explain to me why the two codes below have different result? I
thought I can use log(time)~. to replace log(time)~dist+climb+timef.I am using
CVlm from DAAG package. I think nihills is preloaded with the package. Thanks
in advance.
> CVlm(df=nihills, form.lm=formula(log(time)~.)
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 15/02/13 16:06, Duncan Murdoch wrote:
> On 13-02-15 9:54 AM, Rainer M Krug wrote: On 15/02/13 15:41, Duncan Murdoch
> wrote:
On 13-02-15 9:28 AM, Rainer M Krug wrote: Hi
I am sure I am missing something really basic, but I can't fig
How about
c(a, b)
?
HTH,
Giovanni
From: r-help-boun...@r-project.org [r-help-boun...@r-project.org] on behalf of
Nordlund, Dan (DSHS/RDA) [nord...@dshs.wa.gov]
Sent: Thursday, February 14, 2013 7:19 PM
To: r-help
Subject: Re: [R] How to stack row vector
On 13-02-15 9:54 AM, Rainer M Krug wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 15/02/13 15:41, Duncan Murdoch wrote:
On 13-02-15 9:28 AM, Rainer M Krug wrote: Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the l
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 15/02/13 15:41, Duncan Murdoch wrote:
> On 13-02-15 9:28 AM, Rainer M Krug wrote: Hi
>
> I am sure I am missing something really basic, but I can't figure it out.
>
> I want to start R so that I can specify the location for the Library tree. In
>
On 13-02-15 9:28 AM, Rainer M Krug wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the location for the Library tree. In
principel simple:
As I only want it dependent on
Hello,
Use ?merge.
tasks <- read.table(text = "
Task_No Team
A49397 1
B49396 1
", header = TRUE)
ids <- read.table(text = "
IDTeam
A 5019 1
B 472 1
C 140 1
D 5013 1
", header = TRUE)
merge(tasks, ids, all.x = TRUE)
Hope this
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the location for the Library tree. In
principel simple:
As I only want it dependent on the directory I stat R in, I put a .Rprofile
Hi
>
>
> Hello,
>
> I am new to R and have a couple of questions. My data set contains the
> variables "Bwt" and "Hwt", which are bodyweight and heartweight,
> respectively, of a group of cats.
> With the following code, I am making two plots, both to be viewed in
> the same plot window in R:
>
Dear List,
In my previous posting
(https://stat.ethz.ch/pipermail/r-help/2013-February/347593.html), I
refer to playing around with distribution fitting for a particular sort
of data (see dat1 in the previous posting):
I collected absolute node degrees of some network structure and computed
Hello,
I am new to R and have a couple of questions. My data set contains the
variables "Bwt" and "Hwt", which are bodyweight and heartweight, respectively,
of a group of cats.
With the following code, I am making two plots, both to be viewed in the same
plot window in R:
library(MASS)
ma
Hi
The code gives me some warnings but all seems to be OK. 4 points, dashed red
line and error bars. Did you expect some other line?
maybe issue of version/OS? (unstated)
Petr
> sessionInfo()
R Under development (unstable) (2012-10-29 r61044)
Platform: i386-w64-mingw32/i386 (32-bit)
locale:
[1
Hi,
Try this:
dat1<- read.table(text="
Task_No Team
A 49397 1
B 49396 1
",sep="",header=TRUE)
dat2<- read.table(text="
ID Team
A 5019 1
B 472 1
C 140 1
D 5013 1
",sep="",header=TRUE)
res1<- as.matrix(merge(dat1,dat2,by="Team"))
ro
Hi
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
> project.org] On Behalf Of e-letter
> Sent: Friday, February 15, 2013 11:37 AM
> To: Duncan Murdoch
> Cc: r-help@r-project.org
> Subject: Re: [R] plot custom x axis ticks values
>
> On 15/02/2013, Dunc
Hi
?merge
Regards
Petr
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
> project.org] On Behalf Of Mat
> Sent: Friday, February 15, 2013 10:45 AM
> To: r-help@r-project.org
> Subject: [R] match a task No. to a few person-IDs
>
> hello together,
>
> i
Much thanks to both for your advice. I'll take note to post relevant
questions going forward.
Regards,
Ruijie (RJ)
He who has a why can endure any how.
~ Friedrich Nietzsche
On 15 February 2013 21:12, John Fox wrote:
> Dear Ruijie and Bert,
>
> I agree with Bert that it's very diffi
Dear Ruijie and Bert,
I agree with Bert that it's very difficult to do effective statistical
consulting long-distance by email. I think that you'd be much better served by
getting competent statistical help locally, as I've already suggested.
On the other hand, I'm surprised that your reading
Some background: I have some data on structural dependencies in a base
of code artifacts. The dependency structure is reflected in terms of
relative node degrees, with each node representing some code unit (just
as an example).
This gives me real data of the following form (sorry for the longi
hello together,
i have a task No. in a data.frame
Task_No Team
A49397 1
B49396 1
and now i want to match my Person-IDs to each Task_No. My Person Ids look
like this one:
IDTeam
A 5019 1
B 472 1
C 140 1
D 5013 1
Th
HI,
You could also use these:
sapply(groups,paste,collapse=" ")
# 1 3 6
# "6" "4 4" "5 3 2"
#or
gsub("^ | $","",gsub("\\D+"," ",paste(groups)))
#[1] "6" "4 4" "5 3 2"
A.K.
- Original Message -
From: Nikola Janevski
To: r-help@r-project.org
Cc:
Sent: Thu
Dear all,
is it possible to run a post hoc comparison using the glht function on random
factors from a mixed model?
For example, in the model lie(Yield~1+Meadow, random=1|Site/Area/Quadrate).
thank you,
Vasillis Papathanasiou,
Marine SciencesPalaion Fokon 35-37Thessaloniki, 54454Greecetel:+30694
Hello David,
thanks again for your reply.
Two things remain unclear. That the data is disjointed is ok, as there are
only values in hectares, where there are actually buildings and stuff,
forest/nature is NA.
The presp-scan that I get from persp(grd) has no similarity to the image in
2d. My gues
Dear all,
Good day!
I have a question in my codes, would you please help me how to rectify it?
these are my coded but at the last line I received the error!
mac_30 = read.dta("MAC results4.dta")
mac_30
map_30 = read.dta("MAP results4.dta")
map_30
mac_30$weight = 1/nrow(mac_30)
mac_30
map_30$weigh
Martin,
fantastic. thank you *very* much! that clears lots of things up for
me.
(for the record: i think that setGeneric overwriting a previous is more
surprising -- thus violating the principle of least surprise -- than one
function overwriting a previous, in that we think of (or, one way to
t
Dear Giovanna
On 15 February 2013 11:50, Giovanna Ottaviani wrote:
> Anyone familiar with the package frontier? I have some general
> questions on how to approach the model design.
The R package "frontier" is based on "FRONTIER 4.1" [1] but it has
some improvements [2]. The models that can be es
Hello everybody,
Anyone familiar with the package frontier? I have some general questions on how
to approach the model design.
Thanks in advance
Giovanna
Giovanna Ottaviani Aalmo
Stipendiat/Ph.D. Student
---
Norsk institutt for skog og landskap
Pb 115, NO-1
Smells like homework to me. If so, we don't do homework on this list.
-- Bert
On Thu, Feb 14, 2013 at 3:55 PM, email wrote:
> Hello:
>
> I have a 4-column dataset: Crime, Education, Urbanization, Age. I want to
> construct a multiple linear regression to find the effect of Education,
> Urbanizat
On 15/02/2013, Duncan Murdoch wrote:
> On 13-02-15 3:28 AM, e-letter wrote:
>> On 15/02/2013, Jim Lemon wrote:
>>> On 02/14/2013 09:41 PM, e-letter wrote:
Readers,
For this data set:
testvalues<-c(10,20,30,40)
How to amend the plot instruction:
plot(te
On 15-02-2013, at 11:22, Jannetta Steyn wrote:
> Hi Berend
>
> This is the code. Pretty much just changed to what you suggested which is
> CaI=1, removing the unnecessary variables and using deSolve:
>
> rm(list = ls())
> library(deSolve)
> ## Hodkin-Huxley model
> HH_soma <- function(times,
On 02/15/2013 07:28 PM, e-letter wrote:
...
plot(testvalues,ann=FALSE,type='l',yaxt='n',xaxt='n',xlim=c(0,300))
axis(1,at=c(0,100,200,300))
The use of 'xlim' makes the graph unacceptable. Instead, it would be
better to plot:
plot(testvalues,ann=FALSE,type='l',yaxt='n')
The x-axis shows tick ma
Hi Ben
Thank you so much for spending the time to look at my code. I really
appreciate it.
The unnecessary parameters were artefacts from me working on the model and
putting things in and taking things out.
The model isn't quite producing what I expect yet, but it is definitely
starting to look
These are statistical, not R issues, so please do not post further
here. You are clearly out of your depth statistically. You need to get
local statistical help, or you can try posting on a statistical list
like stats.stackexchange.com if you care to take advice from unknown
sources who don't under
Hi Berend
This is the code. Pretty much just changed to what you suggested which is
CaI=1, removing the unnecessary variables and using deSolve:
rm(list = ls())
library(deSolve)
## Hodkin-Huxley model
HH_soma <- function(times, init, parms) {
with(as.list(c(init, parms)),{
# Na only used
On 15-02-2013, at 10:28, Jannetta Steyn wrote:
> Hi Ben
>
> Thank you so much for spending the time to look at my code. I really
> appreciate it.
>
> The unnecessary parameters were artefacts from me working on the model and
> putting things in and taking things out.
>
> The model isn't quite
Sorry that was supposed to be Berend and not Ben
On 15 February 2013 09:28, Jannetta Steyn wrote:
> Hi Ben
>
> Thank you so much for spending the time to look at my code. I really
> appreciate it.
>
> The unnecessary parameters were artefacts from me working on the model and
> putting things in
On 13-02-15 3:28 AM, e-letter wrote:
On 15/02/2013, Jim Lemon wrote:
On 02/14/2013 09:41 PM, e-letter wrote:
Readers,
For this data set:
testvalues<-c(10,20,30,40)
How to amend the plot instruction:
plot(testvalues,ann=FALSE,type='l',yaxt='n',xaxt='n')
so that x axis ticks labels can be a
Thanks Prof Fox for your guidance. My purpose in fitting this model is to
contrast it with another model that I am proposing which I believe will be
a better fit.
On the point of some of the items being close to invariant, I had a close
look at my data and indeed that is the case I am aware of it.
On 15/02/2013, Jim Lemon wrote:
> On 02/14/2013 09:41 PM, e-letter wrote:
>> Readers,
>>
>> For this data set:
>>
>> testvalues<-c(10,20,30,40)
>>
>> How to amend the plot instruction:
>>
>> plot(testvalues,ann=FALSE,type='l',yaxt='n',xaxt='n')
>>
>> so that x axis ticks labels can be added to exi
On 14/02/2013, MacQueen, Don wrote:
>> plot(testvalues,ann=FALSE,type='l',yaxt='n',xaxt='n')
>> par()$usr
> [1] 0.88 4.12 8.80 41.20
>
> The x axis range is from 0.88 to 4.12, so tick labels at 0, 100, 200, 300
> makes no sense.
>
True per se, but the purpose of the tick labels is to indicate
I have no idea what "TACC" is, or what your OS is, or what file networking
scheme your system is using, and these issues are all outside the topic area
for this list. You should go talk to your network admin or local help desk
about how to accomplish this task at the command line, and then if it
76 matches
Mail list logo