Displaying 6 results from an estimated 6 matches for "framename".
2007 Sep 07
3
Plotting lines to sets of points
...have
used the following command to plot the diamond:
plot (0:250, -250:0, type="n", bg="white")
lines(c(125,150,125,100,125),c(-210,-180,-150,-180,-210), col=c("black"))
I have also plotted different hit locations using commands such as the
following:
points(subset(framename$hit_x, framename$hit_traj=="line_drive"),
subset(-framename$hit_y, framename$hit_traj=="line_drive"), pch=20,
col=c("red"))
My question: Is there any easy way to plot a line from the origin (home
plate) to each point on the graph? Preferably the line would share the s...
2008 Sep 28
2
using tapply on a data frame in a function
...rks
outside of a function, but I get the error message from the following code:
"Error in tapply(index, cluster, mean) : arguments must have same length."
Any suggestions? Thanks.
eric
d <- data.frame(cbind(cluster=1:2, value1=1:10, value2=11:20))
d
FindClusterTraits <- function(framename, index){
MeanCluster <- with(framename, tapply(index, cluster, mean))
return(MeanCluster)
}
d2 <- FindClusterTraits(d, 'value1')
[[alternative HTML version deleted]]
2009 Dec 24
2
Column naming issues using read.table
...he data starts on row three and I only need the first
381 data points.
The R error message using the code iv got so far is
Error in read.table(file("s1-2c83.csv"), header = FALSE, sep = ",", quote =
"", :
more columns than column names
The code I have so far is
framename<-read.table(file ("s1-2c83.csv"),
header = FALSE, # FLASE indicates headers are not included in input file
sep = ",", # must have "," otherwise errors in table
quote = "",
dec = ".",
row.names = 1, # must = 1 or extra column of row numbering i...
2001 Apr 06
2
automatic levels
Hello,
I've imported a csv, semi-colon spearated file with read.csv2,
containing one column of rownames and one column of floating point
numbers. When I look at the column of data with framename$columnname, I
get the values of the column plus level values. Are these level values
created automatically ?
The problem is when I try to calcluate the correlation coefficient
between this set of data and another with lm(x~y), the result indicates
that each level seems to have been used as independ...
2007 Jan 09
6
help w/push_event_handler plus doc update request
...uby app but I also need the
flexibility to add event handlers to that main frame.
push_event_handler''s name suggests it''s the way to go but I am not
clear on how to use it. I know that I can add the method that I want
triggered by an event to my frame with
class << frameName
def added_method
...
end
end
but what are the specifics of making the frame-event-method connection?
I want the code to look something like what I''ve pasted below, should
this/ could this work? I''m sorry if I''m going about his all
backwards, but most of m...
2011 Aug 14
0
Improved version of Rprofmem
...tatic int R_MemPagesReporting;
+static int R_MemDetailsReporting;
+static FILE *R_MemReportingOutfile;
+static R_size_t R_MemReportingThreshold;
+static R_len_t R_MemReportingNElem;
+static void R_ReportAllocation (R_size_t, SEXPTYPE, R_len_t);
static void R_ReportNewPage();
-#endif
extern SEXP framenames;
@@ -790,9 +797,7 @@
if (page == NULL)
mem_err_malloc((R_size_t) R_PAGE_SIZE);
}
-#ifdef R_MEMORY_PROFILING
- R_ReportNewPage();
-#endif
+ if (R_IsMemReporting) R_ReportNewPage();
page->next = R_GenHeap[node_class].pages;
R_GenHeap[node_class].pages = page;
R...