[R] Singular Spectrum Analysis Plotting Skipping in a loop, but individually it works

2015-09-27 Thread കുഞ്ഞായി kunjaai
Dear all, I am trying to plot Spectrum of Singular Values using "Rssa" package. I am trying to plot singular spectrum plot inside a loop, it is not plotting, but when I am trying to plot individually in terminal it works, and I can save this as png files. My code is given below: *# --

Re: [R] Appropriate specification of random effects structure for EEG/ERP data: including Channels or not?

2015-09-27 Thread Phillip Alday
You might also want to take a look at the recent paper from the Federmeier group, especially the supplementary materials. There are a few technical inaccuracies (ANOVA is a special case of hierarchical modelling, not the other way around), but they discuss some of the issues involved. And releva

[R] Theme white bands blue and grey or other color

2015-09-27 Thread bgnumis bgnum
Hi all, I want to plot two bands in quant mod but with white theme, chartSeries(Fond,theme="white",TA = c(addBBands(50,2), addBBands(100,2) ) ) The thing is if I put this "t" it plot with black but two bands can be shown, ¿Is it psiible to put the two different bands with white theme¿? t=chartT

[R] FlexBayes installation from R-Forge Problem R 3.2.2

2015-09-27 Thread Davidwkatz
I tried to install FlexBayes like this: install.packages("FlexBayes", repos="http://R-Forge.R.project.org";) but got errors: Here's the transcript in R: R version 3.2.2 (2015-08-14) -- "Fire Safety" Copyright (C) 2015 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 (6

Re: [R] Line in hist count

2015-09-27 Thread bgnumis bgnum
Hi, all I have discovered that with abline(h=dataf,col="red") can add a line as I want in this plot fhist<-hist(f,plot=FALSE) par(mar=c(6,0,6,6)) barplot(fhist$counts/ sum(fhist$counts),axes=FALSE, space=0,horiz=TRUE,col="lightgray") grid() title("Marginal Distribution CDS vs. Ibex",font=4) ablin

[R] How to find out if two cells in a dataframe belong to the same pre-specified factor-level

2015-09-27 Thread trichter
Dear list, I really couldnt find a better way to describe my question, so please bear with me. To illustrate my problem, i have a matrix with ecological distances (m1) and one with genetic distances (m2) for a number of biological species. I have merged both matrices and want to plot both

Re: [R] Variable Class "numeric" instead recognized by dplyr as a 'factor'

2015-09-27 Thread Bert Gunter
Yes, but I think of numeric data with non-numeric values (e.g. "." for missing) as character, not numeric. Missing to me means either empty or with the missing value code specified as you describe. Ergo my comment. Your clarification is nevertheless appropriate. Cheers, Bert Bert Gunter "Data is

Re: [R] Variable Class "numeric" instead recognized by dplyr as a 'factor'

2015-09-27 Thread peter dalgaard
> On 27 Sep 2015, at 22:12 , Bert Gunter wrote: > >> >> Due to missing data, R originally classified each X and Y variable as a >> ‘factor’, subsequently changed to ‘numeric’ via ‘as.numeric’ command. > > No. > a) missing data will not cause numeric data to become factor. There's > something

Re: [R] Excel Price function in R

2015-09-27 Thread peter dalgaard
Given that this requires knowledge of both bond theory and Excel plus a fair amount of effort to understand your code, you are likely to be _so_ on your own However, I'll venture a guess that it has something to do with whether coupons should be discounted until payout or until maturity.

Re: [R] Variable Class "numeric" instead recognized by dplyr as a 'factor'

2015-09-27 Thread Bert Gunter
I believe you need to spend some time with an R tutorial, as I don't believe what you understand what factors are and how they should be used."Dummy variables" are also almost certainly unnecessary and usually undesirable, as well. A few comments below may help.. Cheers, Bert Bert Gunter "Data

Re: [R] Variable Class "numeric" instead recognized by dplyr as a 'factor'

2015-09-27 Thread Thierry Onkelinx
I doubt that dplyr is the problem. have a look at the output of str(CSUdata2) The problem is probably in there. Sending a reproducible example of the problem makes it easier for us to help you. Note that this list doesn't accept HTML mail. I suggest that you read the posting guide carefully. ir.

[R] Variable Class "numeric" instead recognized by dplyr as a 'factor'

2015-09-27 Thread james.vordtriede
Hi--I’m new to R. For a dissertation, my panel data is for 48 Sub-Saharan countries (cross-sectional index=’i’) over 55 years 1960-2014 (time-series index=’t’). The variables read into R from a text file are levels data. The 2SLS regression due to reverse causality will be based on change in

[R] Error finding clusters for new data with FlexMix

2015-09-27 Thread Luiz Alberto Lima
Hello, I am trying to find the clusters for new data using FlexMix. I have the following code: library(flexmix) x <- c(0.605, 0.523, 0.677, 0.101, 0.687, 0.586, 0.517, 0.592, 0.653, 0.617) y <- c(0.222, 0.741, 0.182, 0.162, 0.192, 0.254, 0.745, 0.669, 0.198, 0.214) test <- c(0.720, 0.168, 0.520,

[R] Excel Price function in R

2015-09-27 Thread Amelia Marsh via R-help
Dear Forum, I am using trying to find price of bond in R. I have written the code in line with Excel PRICE formula. However, whenever the residual maturity is less than a year, my R output tallies with the Excel Price formula. However, moment my residual maturity exceeds 1 year, the R output di

Re: [R] Rattle installation

2015-09-27 Thread Giorgio Garziano
This is what I can observe for rattle 3.5.0 on Windows pack <- available.packages() pack["rattle","Depends"] [1] "R (>= 2.13.0), RGtk2" pack["rattle", "Suggests"] [1] "pmml (>= 1.2.13), bitops, colorspace, ada, amap, arules,\narulesViz, biclust, cairoDevice, cba, corrplot, descr, doBy,\ndpl

Re: [R] Truncation of character fields in a data frame

2015-09-27 Thread Duncan Murdoch
On 27/09/2015 7:56 AM, Luigi Marongiu wrote: > Dear all, > I am reading a txt file into the R environment to create a data frame, > however I have notice that some entries have a truncated version of a > field, so for instance I get "Astro" instead of "Astro 1-Astro 1" and > "Sapo" for "Sapo #1-Sap

[R] Truncation of character fields in a data frame

2015-09-27 Thread Luigi Marongiu
Dear all, I am reading a txt file into the R environment to create a data frame, however I have notice that some entries have a truncated version of a field, so for instance I get "Astro" instead of "Astro 1-Astro 1" and "Sapo" for "Sapo #1-Sapo_1" and "Sapo #2-Sapo_2", but I also get "Adeno 40/41

Re: [R] Special characters in regular expressions

2015-09-27 Thread Patrick Connolly
On Thu, 24-Sep-2015 at 12:38PM +0200, peter dalgaard wrote: |> |> On 24 Sep 2015, at 12:05 , Thierry Onkelinx wrote: |> |> > gsub("[A|K]\\|", "", x) |> |> That'll probably do it, but what was the point of the | in [A|K] ?? |> I don't think it does what I think you think it does... |> Somewha