Hi Joseph,
Without a reproducible example, you probably will not get the precise
code for a solution but look at ?list
Rather than doing what you are doing now, put everything into a list,
and then you will not need to use get() at all. You will just work
with the whole list. It can take a bit
How about something like:
If(round(x)!=x){zap} not exactly working code but might help
Ken
On Aug 13, 2554 BE, at 3:42 PM, Paul Johnson wrote:
> A client came into our consulting center with some data that had been
> damaged by somebody who opened it in MS Excel. The columns were
> supposed
Dear R-users,
I've written a script that produces a frequency table for a group of
texts. The table has a total frequency for each word type and
individual frequency counts for each of the files. (I have not
included the code for creating the column headers.) Below is a sample:
Word Total 01
Hello again.
Due to the excellent help from Josh Wiley, I ran back in the C:/R
directory with only changing WIN = 64 in the MkRules.local file (other
than the JPEG, etc). All was well.
Thanks,
Erin
--
Erin Hodgess
Associate Professor
Department of Computer and Mathematical Sciences
Universit
Hi Paul,
What about using:
x[x != as.integer(x)] <- NA
I cannot think of a situation off hand where this would fail to turn
every non integer to missing.
I wonder if there is really a point to this? Can the client proceed
with data analysis with any degree of confidence when an unknown
mechani
Erin,
You can build packages without compiling from source (what made you
think you couldn't?). Did you make sure when you installed the Rtools
(I am assuming you are using those rather than going out and getting
everything you need on your own) that you included everything for 64
bit builds? Wh
Dear R People:
Hope you're having a nice Saturday.
I'm trying to compile R-2.13.1 from source on Windows 7 (64 bit).
I've been able to compile on a 32 bit without any problems.
I changed my BINPREF64, WIN, DEFS_W64 in MkRules.local and did the
usual stuff with the jpeg, etc.
But things are jogg
> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
> On Behalf Of collegegurl69
> Sent: Saturday, August 13, 2011 1:01 AM
> To: r-help@r-project.org
> Subject: Re: [R] Adjacency Matrix help
>
> Thanks so much for your quick reply. it seems to
I'm a property-casualty actuary, use R in at my job, and lurk on the
list. In conjunction with one of its meetings, the Casualty Actuarial
Society (I'm a member) is looking for proposals from people to teach a
workshop in R and I thought members of the list might be interested.
I've pasted the
Good Bless you Duncan. Your explanation is crisp and to the point. Thank you.
--
View this message in context:
http://r.789695.n4.nabble.com/efficient-use-of-lm-over-a-matrix-vs-using-apply-over-rows-tp870810p3742058.html
Sent from the R help mailing list archive at Nabble.com.
_
Hi:
This is worth reading and bookmarking:
http://glmm.wikidot.com/faq
HTH,
Dennis
On Sat, Aug 13, 2011 at 6:31 AM, xy wrote:
> Hi ,
>
> Could someone pls help me about this topic, I dont know how can i extract
> them from my model!!
>
> Thanks,
>
> Sophie
>
> --
> View this message in contex
The help pack says:
use: an optional character string giving a method for computing covariances
in the presence of missing values. This must be (an abbreviation of) one of
the strings "everything", "all.obs", "complete.obs", "na.or.complete", or
"pairwise.complete.obs"
If I used "everything", the
Hello
I have a problem with the following function
(http://www.oga-lab.net/RGM2/func.php?rd_id=ismev:gev.fit):
gev.fit(xdat, ydat = NULL, mul = NULL, sigl = NULL, shl = NULL,
mulink = identity, siglink = identity, shlink = identity,
muinit = NULL, siginit = NULL, shinit = NULL,
show
Thank you, I found this in the help pack:
use: an optional character string giving a method for computing covariances
in the presence of missing values. This must be (an abbreviation of) one of
the strings "everything", "all.obs", "complete.obs", "na.or.complete", or
"pairwise.complete.obs"
I sho
Dear users of R!
I have problems with linear model summary. I do not have any NA values in my
data table, but in summary of linear model there are some NA instead of
resulst. I don´t know why :(
I am interested in ecological factors influencing temperature in ant nest, I
have data concerning ant n
Good Bless you Duncan. Your explanation is crisp and to the point. Thank you.
--
View this message in context:
http://r.789695.n4.nabble.com/efficient-use-of-lm-over-a-matrix-vs-using-apply-over-rows-tp870810p3742043.html
Sent from the R help mailing list archive at Nabble.com.
_
I believe you received an informative answer to both these questions from
Daniel Maiter one hour and twenty five minutes after sending your question:
I repeat it here just in case you didn't get it.
--
Q1 is very opaque because you are not even saying what kind of plot you
Don't forget to load `lattice` package. `latticeExtra` with
`panel.ablineeq` can be also helpful.
This was however for plotting. For subset regression by each WR without
plotting you'd use something like `lapply` or `sapply`.
ans <- sapply(unique(data$WR), function(dir) {
out <- list(lm(PM10~
Hi Sophie,
It is not clear what the degrees of freedom should be in an lmer
model, so their not appearing is intentional. There is fairly
extensive discussion of this topic in the archives for the R-sig-mixed
list.
See, for example: http://rwiki.sciviews.org/doku.php?id=guides:lmer-tests
Cheers
It sounds like the data frame produced by Simulate() doesn't set the names
you want. You can probably fix this by including
colnames(Gestion) < c("B","T1",... # etc)
immediately after the simulation.
Can't confirm this without knowing which of the excel/R interface packages
you're using, but I'd
A client came into our consulting center with some data that had been
damaged by somebody who opened it in MS Excel. The columns were
supposed to be integer valued, 0 through 5, but some of the values
were mysteriously damaged. There were scores like 1.18329322 and such
in there. Until he tracks
For your approach how do you know that either summary or vcov used multiple
imputation? You are using a non-rms fitting function so be careful.
Compare with using the lrm fitting function. Also repace Design with the
rms package.
Please omit confidentiality notices from your e-mails.
Frank
I
On Thu, Mar 31, 2011 at 2:56 PM, Yuelin Li wrote:
> I tried multiple imputation with aregImpute() and
> fit.mult.impute() in Hmisc 3.8-3 (June 2010) and R-2.12.1.
>
> The warning message below suggests that summary(f) of
> fit.mult.impute() would only use the last imputed data set.
> Thus, the who
Hi to all the people again,
I was writting a simply function in R, and wish to collect the results in a
excel file. The work goes as follows,
Ciervos<-function(K1, K0, A, R,M,Pi,Hembras)
{B<-(K1-K0)/A
T1<-(R*Pi*Hembras-M*Pi+B)/(Pi-M*Pi+R*Pi*Hembras)
P1<-Pi-B
R1<-P1*Hembras*R
M1<-P1*M
T2<-(R1-M1+B
Dear R users,
This is most likely very basic question but I am new to R and would really
appreciate some tips on those two problems.
1) I need to plot variables from a data frame. Because of some few high numbers
my graph is really strange looking. How could I plot a fraction of the samples
(
Dear all,
I am calculating each-against-each correlations for a number of
variables, in order to use the correlations as distances. This is easy
enough using just cor(), but not if I want to have a p-value for each
calculated correlation, and especially if I want to correct them for
multiple testi
Hi ,
Could someone pls help me about this topic, I dont know how can i extract
them from my model!!
Thanks,
Sophie
--
View this message in context:
http://r.789695.n4.nabble.com/degrees-of-freedom-does-not-appear-in-the-summary-lmer-tp3741327p3741327.html
Sent from the R help mailing list arc
Hello all,
I am looking at doing text classification on very high dimensional data
(about 300,000 or more features) and upto 2000 documents. I am quite new to
R though, and was just wondering if R and it's libraries would scale to such
high dimensions.
Any thoughts will be much appreciated.
Th
Felix:
Thank you! Perhaps I should read documentation more careful as I missed
that another `at`.
lattice & latticeExtra are so marvelous so I hardly want to use anything
else.
Mikhail
On 08/13/2011 07:31 AM, Felix Andrews wrote:
> You can just specify the label positions, you don't need to give
On Aug 12, 2011, at 7:18 PM, gallon li wrote:
I have a following matrix and wish to define a variable based the
variable
A=matrix(0,5,5)
A[1,]=c(30,20,100,120,90)
A[2,]=c(40,30,20,50,100)
A[3,]=c(50,50,40,30,30)
A[4,]=c(30,20,40,50,50)
A[5,]=c(30,50,NA,NA,100)
A
[,1] [,2] [,3] [,4] [,5
Hi:
Try something like this, using dat as the name of your data frame:
xyplot(PM10 ~ Ref | WR, data = dat, type = c('p', 'r'))
The plot looks silly with the data snippet you provided, but should
hopefully look more sensible with the complete data. The code creates
a four panel plot, one per dire
There may well be more efficient ways to do this, but here's one attempt:
foo <- function(x, val) if(any(x == val, na.rm = TRUE)) which(x == val) else NA
u <- apply(A, 1, function(x) foo(x, 20L))
v <- apply(A, 1, function(x) foo(x, 100L))
ifelse(u < v, v, NA)
[1] 3 5 NA NA NA
HTH,
Dennis
On Fr
Kathie,
It is very difficult to help without adequate information. What does your
objective function look like? Are you maximizing (in which case you have to
make sure that the sign of the objective function is correct) or minimizing?
Can you try "optimx" with the control option all.methods=TR
optimx with BFGS uses optim, so you actually incur some overhead unnecessarily.
And BFGS
really needs good gradients (as does Rvmmin and Rcgmin which are updated BFGS
and CG, but
all in R and with bounds or box constraints).
>From the Hessian, your function is (one of the many!) that have pretty
On 13.08.2011 06:52, bdeep...@ibab.ac.in wrote:
Hello,
I was trying to plot multiple graph using "par(mfrow=c(3,2))".
But this is giving me the following error:
Error in axis(side = side, at = at, labels = labels, ...) :
X11 font -adobe-helvetica-%s-%s-*-*-%d-*-*-*-*-*-*-*, face 1 at size
check
?cor
Please note the parameter 'use'
Weidong Gu
On Sat, Aug 13, 2011 at 9:06 AM, Julie wrote:
> Hello,
> I am quite new to R and I am trying to get a round correlation from a table
> with dozens of columns. However, all the columns contain several blank
> places which show to me as NAs.
your dataframe needs to be called "Nord". If it is not, then replace
"Nord" with the actual name of your dataframe
On Sat, Aug 13, 2011 at 10:43 PM, maggy yan wrote:
> dear R users,
> my data looks like this
>
> PM10 Ref UZ JZ WT RH FT WR
> 1 10.973195 4.338
Hello,
I am quite new to R and I am trying to get a round correlation from a table
with dozens of columns. However, all the columns contain several blank
places which show to me as NAs. Then, when I type round(cor(data),2), I get
no results - everything (except correlation of one column with the sa
The problem is that xyplot tries to evaluate 'groups' in 'data' or in
the formula environment. Your local function environment (where the
variable named "groups" is defined) is neither of these. There are a
couple of ways to get the evaluation to work out; here is one:
pb <- list(F1 = 1:8, F2 = 1:
dear R users,
my data looks like this
PM10 Ref UZ JZ WT RH FT WR
1 10.973195 4.338874 nein Winter Dienstag ja nein West
26.381684 2.250446 nein SommerSonntag nein ja Süd
3 62.586512 66.304869 ja SommerSonntag nein nein Ost
45.59010
You can just specify the label positions, you don't need to give
labels for every color change point:
(there is an 'at' for the color changes and a 'labels$at' for the labels)
levelplot(rnorm(100) ~ x * y, expand.grid(x = 1:10, y = 1:10),
colorkey = list(at = seq(-3,3,length=100),
labe
On 08/13/2011 06:23 AM, erinbspace wrote:
Hello R help!
I am extremely new to R (as in 3 just days) and I've been using it to do
some pretty basic things. I am frustratingly stuck on one point, and am so
so so close to figuring it out, but just far enough away to ask for some
(perhaps embarrassi
On 08/13/2011 04:34 AM, Mikhail Titov wrote:
Hello!
I’d like to have a continuous color bar on my lattice xyplot with colors lets say
from topo.colors such that it has ticks& labels at few specific points only.
Right now I use do.breaks& level.colors with somewhat large number of steps.
The
To be honest,
The first derivative of my objective function is very complicated so I
ignore this. Could it lead to this sort of problem?
Kathie
--
View this message in context:
http://r.789695.n4.nabble.com/optimization-problems-tp3741005p3741010.html
Sent from the R help mailing list archive
Dear R users
I am trying to use OPTIMX(OPTIM) for nonlinear optimization.
There is no error in my code but the results are so weird (see below).
When I ran via OPTIM, the results are that
Initial values are that theta0 = 0.6 1.6 0.6 1.6 0.7. (In fact true vales
are 0.5,1.0,0.8,1.2, 0.6.)
--
Thanks so much for your quick reply. it seems to work. the problem is that it
now places actual zeros on the diagonal whereas the rest of the adjacency
matrix has dots to represent zeroes. Do you have any ideas on how to change
these zeros to dots like in the rest of the adj matrix? Or is it the sa
On Fri, Aug 12, 2011 at 4:23 PM, erinbspace wrote:
> Hello R help!
>
> I am extremely new to R (as in 3 just days) and I've been using it to do
> some pretty basic things. I am frustratingly stuck on one point, and am so
> so so close to figuring it out, but just far enough away to ask for some
>
diag(adjMatrix) <-0
On Aug 13, 2011, at 7:34 AM, collegegurl69 wrote:
> I have created an adjacency matrix but have not been able to figure something
> out. I need to put zeros on the diagonal of the adjacency matrix. For
> instance, location (i,i) to equal 0. Please help. Thanks
_
Hello,
I was trying to plot multiple graph using "par(mfrow=c(3,2))".
But this is giving me the following error:
Error in axis(side = side, at = at, labels = labels, ...) :
X11 font -adobe-helvetica-%s-%s-*-*-%d-*-*-*-*-*-*-*, face 1 at size 8
could not be loaded
Could someone decode this erro
Hi Weidong Gu,
This works! For my clarity, and so I can repeat this process if need be:
The 'mat' generates a matrix using whatever is supplied to x (i.e.
coop.dat) using the columns from position 9:length(x) of 6 columns (by
row).
The 'rem.col' generates a matrix of the first 1:8 columns of 8 c
I have created an adjacency matrix but have not been able to figure something
out. I need to put zeros on the diagonal of the adjacency matrix. For
instance, location (i,i) to equal 0. Please help. Thanks
--
View this message in context:
http://r.789695.n4.nabble.com/Adjacency-Matrix-help-tp3740
Hello R help!
I am extremely new to R (as in 3 just days) and I've been using it to do
some pretty basic things. I am frustratingly stuck on one point, and am so
so so close to figuring it out, but just far enough away to ask for some
(perhaps embarrassingly easy) help.
I have a dataset, visitor
Hello everyone,
Any thoughts in this one please?
The only thing I found was the FSelector package
(http://en.wikibooks.org/wiki/Data_Mining_Algorithms_In_R/Dimensionality_Reduction/Feature_Selection#Aviable_Feature_Ranking_Techniques_in_FSelector_Package).
Unfortunately though it seems to be far
Thanks for your help everyone! I'm happy enough with an asynchronous
solution here. Thanks!
Robert
--
View this message in context:
http://r.789695.n4.nabble.com/Automating-an-R-function-call-tp3740070p3740333.html
Sent from the R help mailing list archive at Nabble.com.
[[alternative HT
54 matches
Mail list logo