search for: huzefa

Displaying 20 results from an estimated 28 matches for "huzefa".

2018 May 08
3
Bilateral matrix
...You can convert the 0s to NA's if you like) Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Tue, May 8, 2018 at 9:21 AM, Huzefa Khalil <huzefa.khalil at umich.edu> wrote: > Dear Miluji, > > If I understand correctly, this should get you what you need. > > temp1 <- > structure(list(id = 101:115, current_location = structure(c(2L, > 8L, 8L, 3L, 6L, 5L, 1L, 2L, 7L, 4L, 2L, 8L, 8L, 3L, 6L), .Label...
2016 Apr 12
0
ggplot2
Hi James, If you want to specify the y-values, you need to use stat="identity" as below: ggplot(probability, aes(x=Fertilizer, y=prob)) + geom_bar(stat="identity", aes(fill=Treatment)) best, huzefa On Tue, Apr 12, 2016 at 1:02 PM, James Henson <jfhenson1 at gmail.com> wrote: > Dear R Community, > > Below is a problem with a simple ggplot2 graph. The code returns the error > message below. > > Error: stat_count() must not be used with a y aesthetic. > > My code i...
2017 Jun 15
0
is.null(mylist[1]) and is.null(mylist$a) returns different values
Thank you all , very informative, never thought of doing a str( mylist[1] ) -----Original Message----- From: "Jeff Newmiller" [jdnewmil at dcn.davis.ca.us] Date: 06/15/2017 11:56 AM To: r-help at r-project.org, "Huzefa Khalil" <huzefa.khalil at umich.edu>, "ce" <zadig_1 at excite.com> Subject: Re: [R] is.null(mylist[1]) and is.null(mylist$a) returns different values I find that the str function is more helpful for understanding the difference between a null list and a list containing a...
2018 May 16
0
Bilateral matrix
Dear Bert and Huzefa, Apologies for the late reply, my account got hacked and I have just managed to recover it. Thank you very much for your replies and the solutions. Both work well. I was wondering if there was any way to ensure (force) that all possible combinations show up in the output. The full dataset has 25...
2016 Apr 12
2
ggplot2
Dear R Community, Below is a problem with a simple ggplot2 graph. The code returns the error message below. Error: stat_count() must not be used with a y aesthetic. My code is below and the data is attached as a ?text? file. # Graph of the probabilities library(digest) library(DT) datatable(probability) str(probability) probability$Fertilizer <- as.factor(probability$Fertilizer)
2017 Jun 15
1
is.null(mylist[1]) and is.null(mylist$a) returns different values
...understanding the difference between a null list and a list containing a null list than the implicit print function call that the interpreter invokes when you enter an expression at the console. str( mylist[1] ) -- Sent from my phone. Please excuse my brevity. On June 15, 2017 8:39:47 AM PDT, Huzefa Khalil <huzefa.khalil at umich.edu> wrote: >Hi, > >Try > >> is.null(mylist[[1]]) >[1] TRUE > >Notice the double square brackets. > >From: ?`[` >"The most important distinction between [, [[ and $ is that the [ can >select more than one element where...
2018 May 15
0
Forecasting tutorial "Basic Forecasting"
...3L), .Dimnames = list(NULL, c("TotalNetRev", "TotalRevAdjusted", "TotalRevCancelled")), .Tsp = c(2016, 2018.25, 12), class = c("mts", "ts", "matrix")) You were correct that the error was because of 28 time-points. This is the fix for it. Huzefa On Tue, May 15, 2018 at 2:08 PM, Bill Poling <Bill.Poling at zelis.com> wrote: > Hi. I am trying to follow this forecasting tutorial at: https://www.r-bloggers.com/basic-forecasting/ > > Using my own data, I cannot get past the first step, lots of laughs. > > dat3 <- struct...
2018 May 16
2
Bilateral matrix
...rt Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Wed, May 16, 2018 at 7:49 AM, Miluji Sb <milujisb at gmail.com> wrote: > Dear Bert and Huzefa, > > Apologies for the late reply, my account got hacked and I have just > managed to recover it. > > Thank you very much for your replies and the solutions. Both work well. > > I was wondering if there was any way to ensure (force) that all possible > combinations show up i...
2017 Jun 15
0
is.null(mylist[1]) and is.null(mylist$a) returns different values
...______________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. -- Huzefa Khalil PhD Candidate, Department of Political Science, University of Michigan
2018 May 15
3
Forecasting tutorial "Basic Forecasting"
Hi. I am trying to follow this forecasting tutorial at: https://www.r-bloggers.com/basic-forecasting/ Using my own data, I cannot get past the first step, lots of laughs. dat3 <- structure(c(5973156.76, 5159011.20, 6695766.64, 6365359.00, 6495218.53, 7226302.39, 6835272.70, 7383501.57, 6962748.19, 7623278.72, 7274994.33 ,7919421.80, 7360740.81, 7436693.35,
2018 May 17
0
Bilateral matrix
...e with having an open mind is that people keep coming along and > sticking things into it." > -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) > > On Wed, May 16, 2018 at 7:49 AM, Miluji Sb <milujisb at gmail.com> wrote: > >> Dear Bert and Huzefa, >> >> Apologies for the late reply, my account got hacked and I have just >> managed to recover it. >> >> Thank you very much for your replies and the solutions. Both work well. >> >> I was wondering if there was any way to ensure (force) that all possible...
2017 Jun 15
4
is.null(mylist[1]) and is.null(mylist$a) returns different values
Hi I have a list : mylist <- list( a = NULL, b = 1, c = 2 ) > mylist[1] $a NULL > is.null(mylist[1]) [1] FALSE > is.null(mylist$a) [1] TRUE why? I need to use mylist[1]
2018 May 04
0
Converting a list to a data frame
...ply(names(x), function(z) > > ata.frame(type=z, x[[z]]))) > > #Error in ata.frame(type = z, dat[[z]]) : still cannot find function > "ata.frame"? > > *William H. Poling, Ph.D.* > > *From:* R-help [mailto:r-help-bounces at r-project.org] *On Behalf Of > *Huzefa Khalil > *Sent:* Wednesday, May 02, 2018 1:24 PM > *To:* Kevin E. Thorpe <kevin.thorpe at utoronto.ca> > *Cc:* R Help Mailing List <r-help at r-project.org> > *Subject:* Re: [R] Converting a list to a data frame > > Hi Kevin, > > There is probably a better way,...
2018 May 04
2
Converting a list to a data frame
...=3:4),B=data.frame(x=5:6,y=7:8)) x2 <- do.call(rbind, lapply(names(x), function(z) ata.frame(type=z, x[[z]]))) #Error in ata.frame(type = z, dat[[z]]) : still cannot find function "ata.frame"? William H. Poling, Ph.D. From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of Huzefa Khalil Sent: Wednesday, May 02, 2018 1:24 PM To: Kevin E. Thorpe <kevin.thorpe at utoronto.ca> Cc: R Help Mailing List <r-help at r-project.org> Subject: Re: [R] Converting a list to a data frame Hi Kevin, There is probably a better way, but it can be done in two steps like this temp...
2005 Jul 14
2
X Windows
Can someone please assist me on how to install Gnome /KDE ? I am running Centos 4.1, and I didn't install the packages durning the install, but would like to install them now, Thanks ZAK CONFIDENTIALITY NOTICE: ************************************************************************ The information contained in this ELECTRONIC MAIL transmission is confidential. It may also be
2017 Aug 14
0
Help creating the IBM Randu function
...______________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. -- Huzefa Khalil PhD Candidate, Department of Political Science, University of Michigan
2018 May 08
0
Bilateral matrix
Dear Miluji, If I understand correctly, this should get you what you need. temp1 <- structure(list(id = 101:115, current_location = structure(c(2L, 8L, 8L, 3L, 6L, 5L, 1L, 2L, 7L, 4L, 2L, 8L, 8L, 3L, 6L), .Label = c("Austin", "Boston", "Cambridge", "Durham", "Houston", "Lynn", "New Orleans", "New York"), class =
2018 May 08
2
Bilateral matrix
I have data on current and previous location of individuals. I would like to have a matrix with bilateral movement between locations. I would like the final output to look like the second table below. I have tried using crosstab() from the ecodist but I do not have another variable to measure the flow. Ultimately I would like to compute the probability of movement between cities (movement to
2017 Aug 14
4
Help creating the IBM Randu function
Dear all, I am trying to learn functions in R and 3D plotting so I decided to try to plot the famous bad PRNG Randu from IBM(1). However something is not correct in the function I have created. First I define the function RANDU like this: > RANDU <- function(num) { return (65539*num)%%(2^31) } and test that it works for a seed of 1: > RANDU(1) [1] 65539 but if I want the next
2018 May 02
0
Converting a list to a data frame
Hi Kevin, There is probably a better way, but it can be done in two steps like this temp <- list(A=data.frame(x=1:2, y=3:4),B=data.frame(x=5:6,y=7:8)) temp <- lapply(names(temp), function(n, temp) { temp[[n]]$type <- n return(temp[[n]]) }, temp = temp) do.call(rbind, temp) On Wed, May 2, 2018 at 1:11 PM, Kevin E. Thorpe <kevin.thorpe at utoronto.ca> wrote: > I suspect