search for: dingjun_cn

Displaying 8 results from an estimated 8 matches for "dingjun_cn".

2005 Sep 18
1
Variable descriptions of a built-in dataset
Hi, everyone, Is there a way to get the detailed variable descriptions of a built-in dataset? By using attributes(Boston) I can get the names of each variables of a builtin dataset 'Boston'(in package "MASS"), but I don't know what each variable means. Can some body tell me how I can get more detailed information about each variable? Thank you! Jun
2006 Jun 21
1
Extract information from the summary of 'lm'
Hi Everyone, I just don't know how to extract the information I want from the summary of a linear regression model fitting. For example, I fit the following simple linear regression model: results = lm(y_var ~ x_var) summary(results) gives me: Call: lm(formula = y_var ~ x_var) Residuals: Min 1Q Median 3Q Max -5.9859 -1.5849 0.4574 2.0163 4.6015 Coefficients:
2004 Dec 16
8
counting numbers without replicates in a vector
Hi, I am just wondering if there is an easy way to count in a numeric vector how many numbers don't have replicates. For example, a=c(1,1,2,2,3,4,5), how can I know there are three numbers (3, 4 and 5) without replicates? Thank you! Jun =====
2005 Dec 29
1
function cv.glm in library 'boot'
Hi, everyone, I have a question regarding function cv.glm in library 'boot'. Basically cv.glm can calculate the estimated K-fold cross-validation prediction error for generalized linear models. My question is this: if I am fitting a logit model, what kind of threshold will it use to calculate the prediction error (saved in 'delta')? It will use 0.5 as the threshold or pick a
2007 Feb 22
0
A question regarding "cutree"
Hi Everyone, I am doing hierarchical clustering analysis and have a question regarding "cutree". I am doing things like this: hc <- hclust(dist(X)) a <- cutree(hc, k=2) Basically "a" is a vector containing the assignments of 1 or 2 for each sample. May I know how "cutree" decides to assign 1 and 2's to each sample (in other words, how clusters 1 and 2
2007 Mar 08
2
alpha parameter in function rgb to specify color
Hi All, In function "rgb", alpha parameter is supposed to set the transparency value. But in my following two examples, it didn't work: plot(1,col = rgb(1,0,0,alpha =0.8)) # as long as alpha < 1, there is no point in the plot. plot(1,col = rgb(0,0,255, alpha=254, maxColorValue=255)) # as long as alpha < 255, there is no point in the plot. Do I use it in the right way? Any
2008 Nov 25
1
row labels in heatmap.2(package gplots)
Dear R users, I have a question regarding how to make row labels readable in a heat map. I have successfully made a heat map using function "heatmap.2" in the package "gplots". However, as there are many rows in the heat map, I have difficulties labeling them (heatmap.2 provides a parameter "labRow" to label the row names, but as I have too many rows, I can not make
2007 Sep 22
2
A weird observation from using read.table
Hi Everyone, Recently I got puzzled by the function read.table, even though I have used it for a long time. I have such a file (tmp.txt, 2 rows and 3 columns, with a space among columns): 1 2'-PDE 4 2 3'-PDE 5 if I do: a = read.table("tmp.txt", header = F, quote = "") a V1 V2 V3 1 1 2'-PDE 4 2 2 3'-PDE 5 Everything is fine. However, if I do: a