similar to: A question on dummy variable

Displaying 20 results from an estimated 9000 matches similar to: "A question on dummy variable"

2002 Jul 02
1
Strange behaviour in plot and points?
Hello R-users I was puzzled by some strange results of an analysis and I found out what is for me a strange behaviour (I won't dare to say a bug) in both plot and points (and I suspect lines and other kind of lower level plots). If you try the following code: > data<-data.frame(dummy1=c(1:10),dummy2=c(1:10)) > plot(data$dummy1,data$dummy3) A plot of the values of dummy1 against
2013 Jun 07
4
matched samples, dataframe, panel data
I R-helpers #I have a data panel of thousands of firms, by year and industry and #one dummy variable that separates the firms in two categories: 1 if the firm have an auditor; 0 if not #and another variable the represents the firm dimension (total assets in thousand of euros) #I need to create two separated samples with the same number os firms where #one firm in the first have a corresponding
2013 Mar 21
4
easy way of paste
Hello, Is there a better way to use paste such as: a = paste(colnames(list.indep)[1],colnames(list.indep)[2],colnames(list.indep)[3],colnames(list.indep)[4],colnames(list.indep)[5],sep="+") > a [1] "aa+dummy1+dummy2+bb+cc" I tried a = paste(colnames(list.indep)[1:5],sep="+") > a [1] "aa" "dummy1" "dummy2"
2013 Mar 21
2
How to store data frames into pdf file and csv file.
Hello, I have a data frame > mdl.summary est.coef std.err t.stat intercept 0.0011625517 0.0002671437 4.351784 aa -0.0813727439 0.0163727943 -4.969997 dummy1 -0.0002534873 0.0001204000 -2.105376 dummy2 -0.0007784864 0.0001437537 -5.415417 bb -0.0002856727
2011 Jan 03
1
Formatted output with alternating format at different rows
Dear all, I have a simple question. I couldn't find a solution in the forums/R-user manual; I have also asked to my friends who use R, but couldn't get any answer from them either. I would appreciate any solutions. I want to write formatted text file like in Fortran. More specifically with the format choice of mine for any given line (more specifics are given below). The R function
2001 Mar 13
1
.C-calls
Dear all, (sorry I got the wrong button for subscribing a minute ago) At the moment I'm writing on a package for random field simulation that I'd like to make publically availabe in near future. To this end I've asked Martin Maechler to have a look at my R-code. He was very surprised about how I perform the ".C"-calls, and encouraged me to make this request for comments.
2015 May 27
2
dummy interface shenanigans - CentOS6
tl;dr - a renamed dummy interface is not persisting across reboots on Cent6. I have a situation where I need to rename a dummy interface on my system. I have a total of 3 dummy interfaces: dummy0 dummy1 adummy0 I've been doing some puppet testing in a vbox VM to get this all sorted out to deploy to a group of boxes. Every time I reboot my VM, it comes up WITHOUT adummy0, but I notice
2013 Feb 24
2
[LLVMdev] How to measure the overhead of instrumented code
Hello all, I have developed a instrumented pass which insert some variables between the original variables, as well as insert some code into the original source code. just like: ============= original source code ============= int a[10]; void fun1 () { // some source code here } ========================================= ============= instrumented source code ============= int
2012 Dec 06
1
Can somebody help me with following data manipulation?
Dear all, let say I have following data: dat <- structure(list(V1 = structure(c(1L, 4L, 5L, 3L, 3L, 5L, 6L, 6L, 4L, 3L, 5L, 6L, 5L, 5L, 4L, 4L, 6L, 2L, 3L, 4L, 3L, 3L, 2L, 5L, 3L, 6L, 3L, 3L, 6L, 3L, 6L, 1L, 6L, 5L, 2L, 2L), .Label = c("C", "G", "I", "O", "R", "T"), class = "factor"), V2 = c(0L, 0L, 0L, 1L, 1L, 1L, 1L, 0L,
2015 Jun 17
1
Re: [PATCH v4 1/3] do_btrfs_qgroup_show: fix a bad return value
On Wednesday 17 June 2015 16:19:31 Chen Hanxiao wrote: > We should not use tmp lines buffer as return value, > for lines buffer will be freed. s/tmp/temporary/ > Signed-off-by: Chen Hanxiao <chenhanxiao@cn.fujitsu.com> > --- > v4: take advantage of sscanf's '%m'. > v3: fix test case failure > > daemon/btrfs.c | 40
2009 Sep 04
1
predicting from segmented regression
Hello I'm having trouble figuring out how to use the output of "segmented()" with a new set of predictor values. Using the example of the help file: ??set.seed(12) xx<-1:100 zz<-runif(100) yy<-2+1.5*pmax(xx-35,0)-1.5*pmax(xx-70,0)+15*pmax(zz-.5,0)+rnorm(100,0,2) dati<-data.frame(x=xx,y=yy,z=zz) out.lm<-lm(y~x,data=dati) o<-## S3
2013 Apr 17
2
On matrix calculation
Hello again, Let say I have a matrix: Mat <- matrix(1:12, 4, 3) And a vector: Vec <- 5:8 Now I want to do following: Each element of row-i in 'Mat' will be divided by i-th element of Vec Is there any direct way to doing that? Thanks for your help
2015 May 27
1
dummy interface shenanigans - CentOS6
Frank Even wrote: > On Wed, May 27, 2015 at 1:37 AM, Frank Even > <lists+centos.org at elitists.org> wrote: >> tl;dr - a renamed dummy interface is not persisting across reboots on >> Cent6. >> >> I have a situation where I need to rename a dummy interface on my >> system. >> >> I have a total of 3 dummy interfaces: >> >> dummy0
2015 Oct 15
3
Hide the files that doesn't have permission to access
Thank you guys for your reply. I tried but it still does not work On 10/14/2015 5:37 PM, Stéphane PURNELLE wrote: > > These parameters must be put on share section, not in global section > > hide unreadable = yes > hide unwriteable files = yes > example > > [smb_shr1] > path = /mnt/LV002/share1 > read only = no > create mode = 0777
2015 Jun 23
1
[PATCH] btrfs: remove redundant whitespace
s/ =/ = Signed-off-by: Chen Hanxiao <chenhanxiao@cn.fujitsu.com> --- daemon/btrfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/daemon/btrfs.c b/daemon/btrfs.c index 8b5779a..306cade 100644 --- a/daemon/btrfs.c +++ b/daemon/btrfs.c @@ -512,7 +512,7 @@ do_btrfs_subvolume_list (const mountable_t *fs) goto error; } - struct
2012 Dec 01
4
Getting all possible contingency tables
Hello all, Let say I have 2-way contingency table: Tab <- matrix(c(8, 10, 12, 6), nr = 2) and the Chi-squared test could not reject the independence: > chisq.test(Tab) Pearson's Chi-squared test with Yates' continuity correction data: Tab X-squared = 1.0125, df = 1, p-value = 0.3143 However I want to get all possible contingency tables under this independence
2018 Mar 04
3
Change Function based on ifelse() condtion
Below is my full implementation (tried to make it simple as for demonstration) Lapply_me = function(X = X, FUN = FUN, Apply_MC = FALSE, ...) { if (Apply_MC) { return(mclapply(X, FUN, ...)) } else { if (any(names(list(...)) == 'mc.cores')) { myList = list(...)[!names(list(...)) %in% 'mc.cores'] } return(lapply(X, FUN, myList)) } } Lapply_me(as.list(1:4), function(xx) { if (xx ==
2010 Jul 10
7
Need help on date calculation
Hi all, please see my code: > library(zoo) > a <- as.yearmon("March-2010", "%B-%Y") > b <- as.yearmon("May-2010", "%B-%Y") > > nn <- (b-a)*12 # number of months in between them > nn [1] 2 > as.integer(nn) [1] 1 What is the correct way to find the number of months between "a" and "b", still
2018 Mar 04
0
Change Function based on ifelse() condtion
The reason that it works for Apply_MC=TRUE is that in that case you call mclapply(X,FUN,...) and the mclapply() function strips off the mc.cores argument from the "..." list before calling FUN, so FUN is being called with zero arguments, exactly as it is declared. A quick workaround is to change the line Lapply_me(as.list(1:4), function(xx) { to Lapply_me(as.list(1:4),
2018 Mar 04
2
Change Function based on ifelse() condtion
My modified function looks below : Lapply_me = function(X = X, FUN = FUN, Apply_MC = FALSE, ...) { if (Apply_MC) { return(mclapply(X, FUN, ...)) } else { if (any(names(list(...)) == 'mc.cores')) { myList = list(...)[!names(list(...)) %in% 'mc.cores'] } return(lapply(X, FUN, myList)) } } Here, I am not passing ... anymore rather passing myList On Sun, Mar 4, 2018 at 10:37 PM,