similar to: Double Colors in Main

Displaying 20 results from an estimated 300 matches similar to: "Double Colors in Main"

2007 Nov 13
1
TRUNCATED error with data frame
Hi , I am new to R. I am trying to run a simple R script as shown below: aov.R ------ data1<-c(49,47,46,47,48,47,41,46,43,47,46,45,48,46,47,45,49,44,44,45,42,45,45,40 ,49,46,47,45,49,45,41,43,44,46,45,40,45,43,44,45,48,46,40,45,40,45,47,40) matrix(data1, ncol= 4, dimnames = list(paste("subj", 1:12), c("Shape1.Color1", "Shape2.Color1", "Shape1.Color2",
2007 Jan 08
3
Relating Tables
I have 2 mysql tables, Product and Color: Color ID ColorName 1 Red 2 Green 3 Yellow 4 Blue Products ID Color1 Color2 Color3 ProductName 1 ? ? ? Orco 2 ? ? ? Skeletor 3 ? ? ? He-Man I need to display the ColorName to
2012 Aug 20
3
select most frequent value in set of variables
Hi, I would like to select the most frequent value level in a set of three variables. Three different observators have judged hair color in study subjects. Mostly they judge the same color, sometimes there is a slight difference. I want to know what most of the observators have chosen (so at least 2) from the 3 observations. E.g. If two out of three observators decide the hair is black, then
2016 Apr 07
2
simple question on data frames assignment
If you are not using an anonymous function and say you had written the function out The below gives me the error > 'f(colordata2$color1)' is not a function, character or symbol' But then how is the anonymous function working? f <- function(col){ ifelse(col == 'blue', 1, 0) } responses <- lapply(colordata2[ -1 ], f(colordata2$color1) )
2016 Apr 07
0
simple question on data frames assignment
lapply(colordata2[ -1 ], f ) When you put the parentheses on, you are calling the function yourself before lapply gets a chance. The error pops up because you are giving a vector of numbers (the answer f gave you) to the second argument of lapply instead of a function. -- Sent from my phone. Please excuse my brevity. On April 7, 2016 7:31:18 AM PDT, Michael Artz <michaeleartz at
2008 Aug 06
2
Attempting to make a custom color spectrum to use in heatmap.2
Hello there! I'd just like to say in advance, "Thank you," for any help and/or advice. My problem is as follows: I have a dataset that is made up of percentages. I've assigned my "error" percentages a value of '-100', my "non-existent" percentages a value of '0', and all my other percentages are normal values that range from the high
2016 Apr 07
0
simple question on data frames assignment
Lapply is not a vectorized function. It is compact to read, but it would not be worth using for this calculation. However, if your data frame had multiple color columns in your data frame that you wanted to make responses for then you might want to use lapply as a more compact version of a for loop to repeat this operation. colordata2 <- data.frame(id = c(1,2,3,4,5), color1 =
2008 Jan 23
1
Bar width and labels in barchart
Hi everyone I am using barchart to make my graphs. Here is my code. barchart(percent_below ~ factor(Year)| factor(Season, levels=unique(Season)), data= .season_occurrence, origin = 0, layout = c(4, 1), scales=list(tick.number=ticknum,labels=NULL), ylim=c(0, ymax), group = factor(Year), xlab= "Year", auto.key = list(points = FALSE, rectangles =
2010 Mar 07
1
duplicate STRSXP : shallow copy ?
Hello, As this little program illustrates, duplicating a STRSXP does not seem deep enough. require( inline ) fx <- cfunction( signature( x = "character"), ' SEXP y = PROTECT( duplicate( x ) ); int n = LENGTH(x); int nc = 0 ; char* p = 0 ; for( int i=0; i<n; i++){ p = (char*)( CHAR( STRING_ELT( y , i ) ) ); nc = strlen( p ) ; for( int j=0; j<nc; j++){ p[j] =
2010 Mar 18
1
Creating Rcpp RcppDatetime from string with millisecond
Hi, I was trying to generate RcppDatetime from a string. The main problem for me is that my string contains millisecond. I saw that RcppDatetime takes in double of seconds since epoch. I try to generate a double using boost but has no success. I'm wondering if you have any sample snippet? The string looks like: "2010-03-18 15:50:51.232" Secondly, what time zone RcppDatetime is
2010 Feb 20
1
how to create a SEXP which could be accessed in embedded R
Hi all, I am not familiar with writing R extensions. In a C program, I want to create a SEXP and access it in embedded R. How to let the embedded engine know there's a new vector? For example, after creating a SEXP, parsing 'ls()' in embedded R and then evaluating, STRSXP returned will contain the name of the SEXP. Any help would be appreciated. Regards, Spiral [[alternative HTML
2010 Mar 03
1
Mentor for GSOC '10: Symbolic Regression in R
Hi all, I am looking to extend the regression and data analysis capabilities of R through Symbolic Regression that can potentially find implicit equation relationships in the input data. You can find my project proposal at: http://rwiki.sciviews.org/doku.php?id=developers:projects:gsoc2010:syrfr I am looking for a mentor to guide me through the summer on the project under the Google Summer Of
2010 Mar 30
2
Trouble in using rJava
Hello, I'm using rJava and JRI to call R scripts from my Java code, but my scripts are sometimes executed, and very often they don't run throwing a Java exception. I'm using a 2.7 version of R, with rJava 0.8.4 and Java Sun 1.6. Somebody can help me please ?? Thank you very much, Nabila
2010 Mar 19
1
Can't setup rJava under ubuntu
When I try to install rJava, I get the following error: > install.packages('rJava') ... checking whether siglongjmp is declared... yes checking Java support in R... present: interpreter : '/usr/bin/java' archiver : '/usr/bin/jar' compiler : '/usr/bin/javac' header prep.: '/usr/bin/javah' cpp flags :
2010 Mar 22
3
Embed R code in C++
Hi, Can anyone tell me how to embed R code in a C++ file. I am actually using a mac running on the OSX 10.6.2 and the IDE Xcode Version 3.2 and I would like to embed the basic function like geometric, binomial, normal and hyper geometric distributions in a sample cpp file. I heard about the library RInside and i have downloaded the source code for mac but i do not know how to build it in
2010 Mar 25
1
Error using Rcpp
Hi, Im not sure if this is the right place to post this. I am using Xubuntu Karmic Koala and am trying to use the Rcpp package. I am testing it using a simple code that takes in a vector and adds 1 to each element: #include <Rcpp.h> // This file takes in a vector and adds one to each entry RcppExport SEXP addone(SEXP vec){ // create a local copy of vec Rcpp::NumericVector
2016 Apr 07
4
simple question on data frames assignment
Thaks so much! And how would you incorporate lapply() here? On Thu, Apr 7, 2016 at 6:52 AM, David Barron <dnbarron at gmail.com> wrote: > ifelse is vectorised, so just use that without the loop. > > colordata$response <- ifelse(colordata$color == 'blue', 1, 0) > > David > > On 7 April 2016 at 12:41, Michael Artz <michaeleartz at gmail.com> wrote: >
2010 Apr 30
2
RInside & child threads
Hi Folks, I am creating a multi-threaded C++ application that initializes RInside in one of the child thread. I would also like to access support interfaces like Rcpp::Environment in the remaining child threads, so that I could access any "R" function associated with the environment initialized. When I run my program, I always get "C Stack limit too huge" errors. I looked
2012 Nov 30
3
(no subject)
Hello R usuer, The code given below superimposes a pie diagram on another plot containing some points. However, I would like to center the pie diagram on the xy location on the plot, but not on the center. is there any way to re-center pic diagram. Any suggestion or better alternative are highly appreciated. Thank you in advance for your help. Regards, Bibke library(visualFields) library(car)
2010 Apr 22
2
RUnit bug?
There appears to be a bug in RUnit. Given a testsuite testsuite.math, say, when I run: runTestSuite(testsuite.math) this works fine, provided there are no extraneous files in the unit test subdirectory. But if there are any Emacs temp files (with names that end with '~') then runTestSuite gets confused and tries to run functions from the temp files as well. [[alternative HTML version