Hi,
I bumped into a serious issue while trying to analyse some texts in
Bulgarian language (with the tm package). I import a tab-separated csv
file, which holds a total of 22 variables, most of which are text cells
(not factors), using the read.delim function:
data<-read.delim("bigcompanies_
Dear all,
According to CHANGES IN R 3.0.0:
o diag() as used to generate a diagonal matrix has been re-written
in C for speed and less memory usage. It now forces the result
to be numeric in the case diag(x) since it is said to have 'zero
off-diagonal entries'.
diag(x) does not
Trying To learn again writes:
> Hi all,
>
> Have any of you instaled R on a Tablet, in this case, which Tablet. My
> family wants me to gift a Tablet but I suposse R can not be instaled on a
> Tablet. And my few "free" time I pass mainly trying to "improve" in R.
>
> Can yoy tell me, if there are
Hi
It seems that some linearisation can be done by
with(dat,plot(exp(Requests), log(1/Time)))
it can be fitted by
fit<-lm(log(1/Time)~exp(Requests), data=dat)
or
library(MASS)
fit.r<-lqs(log(1/Time)~exp(Requests), data=dat)
coef(fit.r)
(Intercept) exp(Requests)
-7.137549922 -0.002378384
f
Hi
What you are seeing may be the effect of kerning.
Try pdf(..., useKerning=FALSE)
Also, make sure that you actually need to use Illustrator. It is
possible that you might be able to do your customisations or refinements
in R, which will greatly improve the chances of being able to
replicat
> Can I "import" the content of a pdf (or jpg) and put it in
> the graphic window?.
jpeg: not in base R, but you could look at the CRAN jpeg package which says it
reads and writes jpegs.
PDF: Not in base R. But you can create a PDF with a known filename and then
open it in the default PDF v
Dear Users,
I am a new user of the sem package.
I have a model that is being flagged by sem as "S is numerically singular:
expect problems"
I have checked John Fox's response to a similar problem. Obviously the
variance-covariance matrix is singular, but none of the possible reasons
seems to hold
is there any package available which can be be used to draw us salinity
diagram?
[[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
Hello all,
Sorry if this question has been answered in the past, but I could not find
an answer.
I am trying to print quotes within a cat output. The arguments are:
file= "Data labels"
directory= "/home/mylaptop/"
The function returns:
cat("The file", file, "is located in directory", directory,
Hi Everyone,
I have a very long list of data-points (+2300) and i know from my histogram
that there are outliers which are affecting my mean.
I was wondering if anyone on here knows a way i can quickly get R to
calculate and remove data which is 3 standard deviations from the mean? I am
hoping
Thanks for the explanations.
Wouldn't the following bit of checking in do.call() make it easier to figure
such things out in the future?
my.call <- function(what,args,...) {
## Get the name of the function to call.
if (!is.character(what))
whatStr <- deparse(substitute(what))
el
Michael Haenlein wrote
Dear all,
I would like to use predict.lm to obtain a set of predicted values
based on
a regression model I estimated.
When I apply predict.lm to two vectors that have the same values, the
predicted values will be identical. I know that my regress
Try:
directory= "\"/home/mylaptop/\""
Hope this helps,
Adrian
On Tue, Apr 9, 2013 at 1:06 PM, Daniel Caro wrote:
> Hello all,
>
> Sorry if this question has been answered in the past, but I could not find
> an answer.
>
> I am trying to print quotes within a cat output. The arguments are:
>
>
file<- "\"Data labels\""
directory="\"/home/mylaptop/\""
cat("The file", file,"is located in directory",directory,sep=" ")
The file "Data labels" is located in directory "/home/mylaptop/"
A.K.
- Original Message -
From: Daniel Caro
To: r-help@r-project.org
Cc:
Sent: Tuesday, April 9,
On Tue, Apr 9, 2013 at 7:31 AM, Harry Mamaysky wrote:
> Thanks for the explanations.
>
> Wouldn't the following bit of checking in do.call() make it easier to figure
> such things out in the future?
>
Sure, it would have helped you figure out your issue, but you don't
want a *warning* when you pu
Hi,
On Apr 9, 2013, at 6:12 AM, Amit Ghosh wrote:
> is there any package available which can be be used to draw us salinity
> diagram?
If you have CTD data and are looking to plot temperature-salinity diagrams,
then I highly recommend Dan Kelley's "oce" package.
Cheers,
Ben
Ben Tupper
Bigelow
That's true. So perhaps there should be a flag that turns on this error
checking. Often "args" is just a list that gets generated automatically and you
don't know what all of its elements are. It just leads to a bit of
non-deterministic behavior. It would be useful to have the option of flagging
On 09-04-2013, at 13:12, Lorna wrote:
> Hi Everyone,
>
> I have a very long list of data-points (+2300) and i know from my histogram
> that there are outliers which are affecting my mean.
>
> I was wondering if anyone on here knows a way i can quickly get R to
> calculate and remove data which
Dear Amarnath Bose,
S is the observed-variables covariance or moment matrix and thus doesn't
really have to do with the model that you're fitting, nor with the sem
software per se; rather, S is computed directly from the data.
It's not possible without the data to know why S is numerically singu
On Apr 9, 2013, at 4:12 AM, Lorna wrote:
Hi Everyone,
I have a very long list of data-points (+2300) and i know from my
histogram
that there are outliers which are affecting my mean.
I was wondering if anyone on here knows a way i can quickly get R to
calculate and remove data which is 3 s
On Tue, Apr 9, 2013 at 3:06 AM, Daniel Caro wrote:
> Hello all,
>
> Sorry if this question has been answered in the past, but I could not find
> an answer.
>
> I am trying to print quotes within a cat output. The arguments are:
>
> file= "Data labels"
> directory= "/home/mylaptop/"
>
> The functio
On Tue, Apr 9, 2013 at 9:15 AM, Harry Mamaysky wrote:
> That's true. So perhaps there should be a flag that turns on this error
> checking. Often "args" is just a list that gets generated automatically and
> you don't know what all of its elements are. It just leads to a bit of
> non-determinis
That's a nice solution. Thanks.
Sent from my iPhone
On Apr 9, 2013, at 10:00 AM, Gabor Grothendieck wrote:
On Tue, Apr 9, 2013 at 9:15 AM, Harry Mamaysky wrote:
> That's true. So perhaps there should be a flag that turns on this error
> checking. Often "args" is just a list that gets generat
Hi,
You could try this:
v <- c("a", "b")
mat1<-diag(length(v))
diag(mat1)<- v
mat1
# [,1] [,2]
#[1,] "a" "0"
#[2,] "0" "b"
v1<- letters[1:5]
mat2<- diag(length(v1))
diag(mat2)<- v1
mat2
# [,1] [,2] [,3] [,4] [,5]
#[1,] "a" "0" "0" "0" "0"
#[2,] "0" "b" "0" "0" "0"
#[3,]
There are two misspellings in the german Error message for friedman test:
Fehler in friedman.test.default(cont$score, group = cont$goup, blocks =
cont$cont) :
y, Gruppen und blöcke müssen die sekbe Länge haben
The correct spelling would be:
Fehler in friedman.test.default(cont$score, group
#Dear all,
#Could anyone help me with the following?
#DATA
num <- as.numeric(seq(100:125))
ave <- c(0.5, 1, 1.6, 2, 2, 2.3, 2.5, 2.4, 3, 3.2, 3.3, 4, 4.8, 3.5, 2.7, 3.1,
2.8, 3.5, 4.1, 2.0, 2.5, 2.1, 3.4, 2.5, 2.6, 7)
DATA <- data.frame(cbind(num, ave))
rm(num, ave)
#BOXPLOT
x11()
bp <- boxplot(
I was wondering if one can have the coefficients of VAR model sorted
according to variable names rather than lags. If you notice below, the
output is sorted according to lags.
>VAR(cbind(fossil,labour),p=2,type="const")
VAR Estimation Results:
===
Estimated coefficients for
#Dear all,
#Could anyone help me with the following?
#DATA
num <- as.numeric(seq(100:125))
ave <- c(0.5, 1, 1.6, 2, 2, 2.3, 2.5, 2.4, 3, 3.2, 3.3, 4, 4.8, 3.5, 2.7, 3.1,
2.8, 3.5, 4.1, 2.0, 2.5, 2.1, 3.4, 2.5, 2.6, 7)
DATA <- data.frame(cbind(num, ave))
rm(num, ave)
#BOXPLOT
x11()
bp <- boxplot(
Estimada Beatriz,
If you use the Box.plot function in the car package (notice that here it's
Box.plot, not box.plot), and add the argument id.method=c("identify"), it
should work.
You only need one instruction:
R> library(car)
R> bp <- Boxplot(DATA$ave, data= DATA, main= "Average
Size",id.meth
p <- boxplot(dat1$ave, data= dat1, main= "Average Size", yaxt = "n")
text(1.1, , y = max(dat1$ave), label = "26", cex = .7)
but I don't understand
#I would like the labels that appear in the boxplot to be DATA$num values.
You want 26 values potted?
John Kane
Kingston ON Canada
> ---
On 2013-04-09 7:35, kais...@med.uni-duesseldorf.de wrote:
There are two misspellings in the german Error message for friedman test:
Fehler in friedman.test.default(cont$score, group = cont$goup, blocks =
cont$cont) :
y, Gruppen und blöcke müssen die sekbe Länge haben
The correct spellin
Dear list,
I have found an unusual behavior and would like to check if it is a
possible bug, and if updating R would fix it. I am not sure if should post
it in this mail list but I don't where is R bug tracker. The only mention I
found that might relate to this is "If times is a computed quantity
Dear all,
I have just sent an enquiry but probably I hadnât expressed myself properly.
Could anyone help me with the following?
When I run the code on my data I get a boxplot with outliers identified by
numbers 200 & 201.
However, what I would like is to label these outliers with their corre
FYI,
> (0.29*100) < 29
[1] TRUE
See R FAQ 7.31 for why.
/Henrik
On Tue, Apr 9, 2013 at 9:11 AM, Jorge Fernando Saraiva de Menezes
wrote:
> Dear list,
>
> I have found an unusual behavior and would like to check if it is a
> possible bug, and if updating R would fix it. I am not sure if should
Hello,
The construct data.frame(cbind(...)) is not at all needed, the following
is much better.
dat1 <- data.frame(num, ave)
Also, I've modified the text() call a bit, in order to have R tell the
dat1$num corresponding to the (unique) max of ave, and with an extra
argument, pos. This would
Dear Milan and David,
Thank you both very much for your help! I finally figured it out.
Text on the website was UTF-8, but in the process of downloading it using
RDF, it got converted to the java/javascript encoding. To convert it back
to UTF-8:
> test <- "4.5\\u00B5g of cDNA was used"
> iconv
On Tue, Apr 9, 2013 at 7:15 AM, Mike Cheung wrote:
> Dear all,
>
> According to CHANGES IN R 3.0.0:
> o diag() as used to generate a diagonal matrix has been re-written
> in C for speed and less memory usage. It now forces the result
> to be numeric in the case diag(x) since it is sa
The problem is that identify() is designed for a scatterplot not a boxplot.
You can use it but you have to feed it the correct x and y coordinates:
identify(rep(1, nrow(DATA)), DATA$ave, cex=.7)
This will give you "26" as you requested if you click on the outlying point.
That is the row name for
Possibly R FAQ 7.31
length(rep(TRUE,signif(0.29*100,2)))
#[1] 29
A.K.
- Original Message -
From: Jorge Fernando Saraiva de Menezes
To: r-help@r-project.org
Cc:
Sent: Tuesday, April 9, 2013 12:11 PM
Subject: [R] rep() fails at times=0.29*100
Dear list,
I have found an unusual behavior
[See at end]
On 09-Apr-2013 16:11:18 Jorge Fernando Saraiva de Menezes wrote:
> Dear list,
>
> I have found an unusual behavior and would like to check if it is a
> possible bug, and if updating R would fix it. I am not sure if should post
> it in this mail list but I don't where is R bug tracker.
Hi,
I have used R to run a confirmatory factor analysis using the sem package.
The analysis has run ok, but I am missing some information (e.g., Tucker
Lewis Index, RMSEA) I was wondering if there was a reason for this, I have
though it may be due to the low sample size?
Any help would be appreci
Thank for your help, and sorry for posting before reading the FAQ, I know
it is one of the basic rules. Though, knowing myself I would never relate
the error in rep with 0.29*100!=29
2013/4/9 arun
> Possibly R FAQ 7.31
>
> length(rep(TRUE,signif(0.29*100,2)))
> #[1] 29
> A.K.
>
>
> - Origi
I could not locate any package (using RSeek.org) to compute sensitivity,
specificity and related measures, for logistic regression models with
grouped data. (For ungrouped data I know one, the SMDTools). Any suggestion
will be greatly appreciated.
Many thanks
Endy
[[alternative HTML versi
Hello,
The answers you had in another thread could lead you to
bp <- boxplot(DATA$ave, data= DATA, main= "Average Size")
idx <- which(DATA$ave %in% bp$out)
text(x= bp$group, y= bp$out, labels= DATA$num[idx], cex = 0.7, pos = 4)
Hope this helps,
Rui Barradas
Em 09-04-2013 17:31, Beatriz Gonzá
I have a generalized linear model to solve. I used package "geepack". When
I use the correlation structure "unstructured", I get a messeage that- R
GUI front-end has stopped working. Why this happens? What is the solution?
The r codes are as follows:
a<-read.table("d:/bmt.txt",header=T")
cutoffs<-c
Dear Laura,
In the current version of the Rcmdr package, output of "fit indices" beyond
the LR test, AIC, and BIC is optional, and is controlled by the fit.indices
argument to the summary() method (see ?summary.objectiveML) or by the
fit.indices option. Everyone seems to have different preferences
Le mardi 09 avril 2013 à 10:10 +0300, Ventseslav Kozarev, MPP a écrit :
> Hi,
>
> I bumped into a serious issue while trying to analyse some texts in
> Bulgarian language (with the tm package). I import a tab-separated csv
> file, which holds a total of 22 variables, most of which are text cells
Dear R experts,
I hope this is the right list for my question.
As a newcomer in R, I am testing the R CAPER package, applying a simple
regression on a phylogeny tree with three binary traits: (t1, t2, t3).
My goal is to test the sensitivity to a correlation between t1 and t3. But
if a correlatio
Hi,
Is there a way to calculate the number of peaks produced when running acf
on time series data? What I'm looking for is a way to calculate the number
of peaks that are greater than the confidence limits if the lag is preset
and constant.
thanks for any help you are able to give,
Aimee.
Hi,
I have used sem package to run confirmatory factor analysis. The analysis
has run ok, but I am missing some information (e.g., Tucker
Lewis Index, RMSEA) I was wondering if there was a reason for this, I have
though it may be due to the low sample size?
Any help would be appreciated.
Many Th
Dear people,
I used clusplot to plot a partition result. The partition result was from
pamk with a distance object as input. Then I applied cmdscale on the same
distance object for coordinates to make another scatterplot.
My problem is this: the coordinates from the cmdscale calculation, though
w
Hi,
Try this:
source("catalin2.txt")
dat2$year<- as.numeric(row.names(dat2))
indx<-findInterval(dat2$year,seq(1591,1700,by=10)) #based on the last row in
the dataset
group<-seq(1590,1700,by=10)
ind<-seq(1,length(group),by=1)
labl1<-paste(group[ind],group[ind+1],sep="-")
labl1<- labl1[-length(la
str() takes 2+ minutes to print
--8<---cut here---start->8---
'data.frame': 9445743 obs. of 25 variables:
$ share.id: Factor w/ 1641168 levels "387059b61ffef5cf",..: 7 118 118
209 242 242 254 254 263 291 ...
...
--8<---cut here---
Hello,
I'm glad it help. You should cc the list, maybe it will be of use to others.
Rui Barradas
Em 09-04-2013 21:00, Beatriz González Domínguez escreveu:
I have solved it, many thanks!
-Original Message- From: Rui Barradas
Sent: Tuesday, April 09, 2013 7:33 PM
To: Beatriz González Do
Hello All,
Would like to be able to convert a matrix to a dataframe without losing an
assigned dimname.
Here is an example that should illustrate what I'm talking about.
tableData <- state.x77[c(7, 38, 20, 46), c(7, 1, 8)]
names(dimnames(tableData)) <- c("State", "")
tableData
State F
On 13-04-09 6:06 AM, Daniel Caro wrote:
Hello all,
Sorry if this question has been answered in the past, but I could not find
an answer.
I am trying to print quotes within a cat output. The arguments are:
file= "Data labels"
directory= "/home/mylaptop/"
The function returns:
cat("The file", f
On 13-04-09 9:35 AM, kais...@med.uni-duesseldorf.de wrote:
There are two misspellings in the german Error message for friedman test:
Fehler in friedman.test.default(cont$score, group = cont$goup, blocks =
cont$cont) :
y, Gruppen und blöcke müssen die sekbe Länge haben
The correct spelling
Hello everyone,
I was trying to do some distribution fitting with a numerical field called
Tolls. The sample size = 999 rows.
Basically I assigned the Toll data to a new variable K by doing:
k<-dtest$Toll
After that, tried to fit a gamma distribution by doing: fitG<-fitdist(k,
"gamma")
Then th
>
> Hello everyone,
>
>
> I was trying to do some distribution fitting with a numerical field
> called Tolls. The sample size = 999 rows.
>
> Basically I assigned the Toll data to a new variable K by doing:
> k<-dtest$Toll
>
> After that, tried to fit a gamma distribution by doing: fitG<-fitdist
On Tue, Apr 9, 2013 at 4:52 PM, Paul Miller wrote:
> Hello All,
>
> Would like to be able to convert a matrix to a dataframe without losing an
> assigned dimname.
>
> Here is an example that should illustrate what I'm talking about.
>
> tableData <- state.x77[c(7, 38, 20, 46), c(7, 1, 8)]
> names
On 13-04-09 2:41 PM, Tasnuva Tabassum wrote:
I have a generalized linear model to solve. I used package "geepack". When
I use the correlation structure "unstructured", I get a messeage that- R
GUI front-end has stopped working. Why this happens? What is the solution?
Presumably geepack has a bu
Hi
I am tring to making a dengrogram. I know how to make a normal dengrogram.
But I want to know if there is certain option.
My dengrogram will be clustered using a value called MatchPrint. But now I
want another value called matchscore displayed next to the leaves. The value
matchscore next to t
Interesting. The problem is that only ***arrays*** are allowed to have
a dimnames attribute, and data frames are not arrays (they are lists).
The only way that I can see to achieve the effect that you want is to
make the row names into the first column of your data frame and wipe
out the row na
Hello all!
I have a big problem now. I want a data frame like this:
dput(head(test,100))
structure(c(NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA
Hi,
library(plyr)
library(reshape2)
df2<-mutate(dcast(melt(tableData),State~Var2),
State=factor(State,levels=rownames(tableData)))
dfNew<-df2[as.numeric(df2$State),c(1,3:4,2)]
dfNew$State<- as.character(dfNew$State)
dfNew
# State Frost Population Area
#1 Connecticut 139 3100
Hi,
please give a *small* working example or everyone will have to guess
what could be right.
see text for drawing text and rect(x1,y1,x2,y2,col,...) for drawing
colred rectangles.
Regards, Moritz
On 09.04.2013 23:34, gunturus wrote:
> Hi
>
> I am tring to making a dengrogram. I know how to ma
Moved to R-help because there's no obvious financial content.
Michael
On Sat, Apr 6, 2013 at 10:56 AM, Stat Tistician
wrote:
> Hi,
> I want to implement the EM algorithm manually, with my own loops and so.
> Afterwards, I want to compare it to the normalmixEM output of mixtools
> package.
>
> Si
Hi,
I am trying to run a 1D nutrient-phytoplankton-zooplankton model in R
using the package 'deSolve'. The code is shown below:
DEPTH = seq(2.5, 147.5, 5)
NPZ = function(t, state, params){
with(as.list(params), {
P <- state[1:NB]
Z <- state[(NB + 1): (2*NB)]
N <- state[(2*NB + 1
Hello R-users,
I am trying to do an image plot where I have been given latitudes,
longitudes and the values at the corresponding locations. A sample of the
data is given as follows:
values=c(0,1,0,0,0,0,2,2,0,0)
lat=c(29.6660,29.6756,29.3492,29.2654,29.2827,29.4070,35.3510,35.6590,35.7587,38.2
Hi,
Did you carefully read the help for "image" ?
## Default S3 method:
image(x, y, z, zlim, xlim, ylim, col = heat.colors(12),
add = FALSE, xaxs = "i", yaxs = "i", xlab, ylab,
breaks, oldstyle = FALSE, useRaster, ...)
Regards,
Pascal
On 04/10/2013 10:07 AM, cassie jones wrote:
H
Hi,
How can I plot two curves with distinct x and y vectors? I would like to
join one of them by regular lines and plot the other just by points (no
lines). Can it be done in regular R graphic tools, say "plot" function?
Can it be done in Lattice package, say "xyplot" function?
Thanks,
Mi
Yes, I did. But I get the following error with the command
image(x=long,y=lat,z=values)
"Error in image.default(x=long,y=lat,z=values):
error in evaluating the argument 'x' in selecting a method for function
'image': Error in long: recursive indexing failed at level 2"
Thanks,
Cassie
On Tue, A
Hi,
This should be fairly easy by using base R graphics.
Lets suppose your first data is represented by (x1,y1) and second data is
represented by (x2,y2)
You can use the following command.
plot(x1,y1,type="l")
points(x2,y2)
Hope it helps.
On Tue, Apr 9, 2013 at 8:24 PM, jpm miao wrote:
> Hi
Hello,
In the case:
image(x=long,y=lat,z=values)),
"long" is not in (strictly) ascending order, according to the sample you
provided:
plot(long)
Regards,
Pascal
On 04/10/2013 10:28 AM, cassie jones wrote:
Yes, I did. But I get the following error with the command
image(x=long,y=lat,z=val
Thanks, A.K.
I managed to create diagonal matrices for character vectors. Since this new
behavior broke a package that I have written, I would like to make sure
that this new behavior was not introduced by mistakes. If this new behavior
is final, I will modify my code to fit it.
Mike
On Tue, Ap
Thank you very much.
Could it be done in Lattice package?
Thanks,
Miao
2013/4/10 Janesh Devkota
> Hi,
>
> This should be fairly easy by using base R graphics.
>
> Lets suppose your first data is represented by (x1,y1) and second data is
> represented by (x2,y2)
>
> You can use the following
Dear R users,
I recently upgraded R from version 2.15.3 to version 3.0.0 (after
removing version 2.15.3 and cleaning installation directory) using the
package provided by openSUSE (R-base).
I am now running into an issue when two loaded packages share the same
name for a function.
For exam
Hi,
I'm used the pscl library to fit a zero inflated poisson model.
My data has 25,327 rows (no missing values.)
zeroinfl(y ~ x) works fine. I get coefficients, etc.
Now, I want to see the fitted values and do some comparisons to the truth. So
I used:
predict(mod, type="count)
The result
On Apr 9, 2013, at 8:21 PM, jpm miao wrote:
Thank you very much.
Could it be done in Lattice package?
Your example was not presented in a form that lent itself to easy
editing. Please learn to use dput to present data structures:
xyplot( 4:6 ~ 1:3,
panel=function(x,y) {
79 matches
Mail list logo