Paul | 21 Apr 01:04 2015
Picon

How numerical data is stored inside ts time series objects

I'm getting familiar with the stl function in the stats packcage by
trying it on an example from Brockwell & Davis's 2002 "Introduction to
Times Series and Forcasting".  Specifically, I'm using a subset of his
red wine sales data.  It's a detour from the stl material at
http://www.stat.pitt.edu/stoffer/tsa3/R_toot.htm (at some point, I
have to stop simply following and try to make it work with new data).

I need a minimum of 36 wine sales data points in the series, since stl
otherwise complains about the data being less than 2 cycles.  The data
is in ~/tmp/wine.txt:

    464
    675
    703
    887
    1139
    1077
    1318
    1260
    1120
    963
    996
    960
    530
    883
    894
    1045
    1199
    1287
    1565
(Continue reading)

Carlijn Wibbelink | 20 Apr 22:05 2015
Picon

Metafor - rma.mv function - variance components

Hi all,

I have a question about metafor and the rma.mv function. I have fitted a multivariate model (effect sizes
are nested within studies) and I've found two variances: 

Variance Components: 
                      estim    sqrt     nlvls  fixed  factor
sigma^2.1  0.0257  0.1602     72     no       y
sigma^2.2  0.0694  0.2635     10     no      ID 

I want to test whether there is significant variantion between the effect sizes within studies
(sigma^2.1: 0.0257) and/or between studies (sigma^2.2: 0.0694). In metaSEM you can fix for example the
variance within studies (sigma^2.1) to zero to test whether there is a significant difference in fit
between the models (and if so, then there is significant heterogeneity between the effect sizes within
studies). I was wondering if this is also possible in metafor. If I fix sigma2 to zero, then both variances
are fixed to zero. However, I want to fix only one variance to zero. 
I hope that someone can help me. Thank you in advance!
 		 	   		  
	[[alternative HTML version deleted]]

ismail hakkı sonalcan | 20 Apr 19:19 2015
Picon

feature selection

Hi,

I want to make feature selection.
Could you help me.

Thanks.
 		 	   		  
John Kane | 20 Apr 19:38 2015

Re: Problem with col


> -----Original Message-----
> From: soniaamin5 <at> gmail.com
> Sent: Mon, 20 Apr 2015 18:56:19 +0200
> To: sarah.goslee <at> gmail.com
> Subject: Re: [R] Problem with col

 --- clip--
> 
> When I type data , I obtain all the numeric values and the headears  I
> added (Consommation,Cylindre,Puissance,Poids)

No you probably do not, as Sarah explained.

As a quick example of the issue look at the two data sets below. Just copy and paste into your R editor.  Both
data sets are in dput() format which is how you should supply sample data to R-help.

ddat1  <-   structure(list(aa = structure(1:4, .Label = c("a", "b", "c",
"d"), class = "factor"), bb = 1:4), .Names = c("aa", "bb"), row.names = c(NA,
-4L), class = "data.frame")

ddat2 <- structure(list(aa = c("a", "b", "c", "d"), bb = c("1", "2", "3", "4")), .Names = c("aa", "bb"),
row.names = c(NA, -4L), class = "data.frame")

If yo do
dat1
dat2
they look the same on the screen but if you do str()  they are not the same.
str(dat1) 
str(dat2)
(Continue reading)

Sarah Goslee | 20 Apr 19:05 2015
Picon

Re: Problem with col

On Mon, Apr 20, 2015 at 12:56 PM, Sonia Amin <soniaamin5 <at> gmail.com> wrote:
> Sorry Sarah  for my basic question: what does "a column was read as factor"
> mean?

A factor is one of the basic types of data in R, and in statistics
generally, eg M/F or red/white/blue - a predetermined set of
categories that may or may not have an order.

More relevantly, if there's something wrong in your data, a stray
letter or quote mark for instance, that column is no longer numeric,
and R will read it as a factor by default, otherwise as character.

str(data)

which is NOT the same as just typing data, will show you the classes
of your columns, among other things.

> When I type data , I obtain all the numeric values and the headears  I added
> (Consommation,Cylindre,Puissance,Poids)

If you just look at data directly, you'll see what look like numbers,
perhaps, but according to R one or more columns are not actually
numbers. That's why you need str(data).

Your problem looks like a lack of basic understanding of how R works.
Here are a couple of sources that might help you get started:
http://www.burns-stat.com/documents/tutorials/impatient-r/
http://cyclismo.org/tutorial/R/

For more help, you should provide at least the output of str(data) to
(Continue reading)

Sonia Amin | 20 Apr 18:33 2015
Picon

Problem with col

Dear All,

I have written the following lines:

 data<-read.table("C:\\Users\\intel\\Documents\\SIIID\\datamultiplereg.txt",header
= FALSE, sep = "")
 colnames(data)<-c("Consommation","Cylindre","Puissance","Poids")
 result.model1<-lm(Consommation~Cylindre+Puissance+Poids, data=data)
summary(result.model1)

I obtained the following message:

Call:
lm(formula = Consommation ~ Cylindre + Puissance + Poids, data = data)

Residuals:
Error in quantile.default(resid) : factors are not allowed
In addition: warning message:
In Ops.factor(r, 2) :
  ‘^’ This is not relevant for factors

Where is the problem?
Thank you in advance

	[[alternative HTML version deleted]]

______________________________________________
R-help <at> r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
(Continue reading)

CHIRIBOGA Xavier | 20 Apr 17:50 2015
Picon

groupedData HELP!

Dear members,

what to do when this appears ?

Error: could not find function "groupedData"

Thanks a lot,

Xavier

j. van den hoff | 20 Apr 17:01 2015

color handling in `barplot' inconsistent betwen `beside=FALSE' and `beside=TRUE'

hi,

consider the following example:

8<-------------------------------------
x <- matrix(1:6, 3, 2)
layout(1:2)
barplot(x, beside = TRUE, col = 1:6)
barplot(x, beside = FALSE, col = 1:6)
8<-------------------------------------

it seems, it is not possible to make `beside=FAlSE' plots behave the same  
as `beside=TRUE' plots (i.e. use unique colors for all bars or bar  
components), or is it? if I do not miss something, I would say the present  
behaviour (as of 3.1.3) is not (or not always, anyway) desirable. rather,  
`beside=FALSE' should use the same color for all bars or bar components as  
`beside=TRUE'.

any opionions on that?

in case someone needs this, the following patch achieves what I would  
expect from `barplot(beside=FALSE, ...)' -- at least w.r.t. colors, if not  
shading ... -- in the first place:

8<-----------------------------------
 <at>  <at>  -96,12 +96,12  <at>  <at> 
      if (beside)
          w.m <- matrix(w.m, ncol = NC)
      if (plot) {
-        dev.hold()
(Continue reading)

Dimitri Liakhovitski | 20 Apr 15:59 2015
Picon

regexpr - ignore all special characters and punctuation in a string

Hello!

Please point me in the right direction.
I need to match 2 strings, but focusing ONLY on characters, ignoring
all special characters and punctuation signs, including (), "", etc..

For example:
I want the following to return: TRUE

"What a nice day today! - Story of happiness: Part 2." ==
   "What a nice day today: Story of happiness (Part 2)"

--

-- 
Thank you!
Dimitri Liakhovitski

Ivan Calandra | 20 Apr 15:32 2015
Picon

list server problem?

Dear all,

I use Thunderbird 31.6.0 on Mac OS 10.6.8 to download my e-mails.
Since this morning, Thunderbird downloads several times the same e-mails 
from the list, some even being from yesterday. It occurs only with 
e-mails from the R-help and not with my other professional and private 
e-mails.

I also checked that it was not a problem with the server on which I get 
e-mails from the R-help: the problematic e-mails are erased every time 
from the server but are received several times. So I would say that the 
R-help server has sent these e-mails several times.

I am wondering if there is currently an issue with the R-help server. Is 
someone else having the same problem?

Thanks!
Ivan

--

-- 
Ivan Calandra, ATER
University of Reims Champagne-Ardenne
GEGENAA - EA 3795
CREA - 2 esplanade Roland Garros
51100 Reims, France
+33(0)3 26 77 36 89
ivan.calandra <at> univ-reims.fr
https://www.researchgate.net/profile/Ivan_Calandra

(Continue reading)

PO SU | 19 Apr 21:42 2015

Two stage cluster in R(two step in spss), which package implement it ?


Dear, expeRts,
  I am confused in finding an implementation of two stage cluster in R(which is two step cluster in spss), i
do some searching, but still can not find it. Has someone happen to know it ?

--

PO SU
mail: desolator88 <at> 163.com 
Majored in Statistics from SJTU
______________________________________________
R-help <at> r-project.org mailing list -- To UNSUBSCRIBE and more, see
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.

Gmane