Closed castower closed 5 years ago
If you run this chunk, what do you get?
```{r}
URL <- "https://raw.githubusercontent.com/DS4PS/Data-Science-Class/master/DATA/syr_parcels.csv"
dat <- read.csv( URL, stringsAsFactors=FALSE )
class( dat$vacantbuil )
If you run this chunk, what do you get?
```{r} URL <- "https://raw.githubusercontent.com/DS4PS/Data-Science-Class/master/DATA/syr_parcels.csv" dat <- read.csv( URL, stringsAsFactors=FALSE ) class( dat$vacantbuil )
This chunk returns logical for me.
Were you reading the data in this way?
If so, then you must be re-casting that variable somehow. That's my best guess without seeing your script.
Were you reading the data in this way?
If so, then you must be re-casting that variable somehow. That's my best guess without seeing your script.
I think I must have re-casted it somehow. However, running that chunk seems to have fixed it because now it is a logical vector again. Thank you!
Yep!
Hello all,
I am currently trying to solve question number 3, "How many vacant BUILDINGS are there in Syracuse (sum over a logical vector)?". However, although the table indicates that vacantbuil is a logical statement, running class(dat$vacantbuil) is returning that it is a character type. I have reloaded the data again, but it keeps telling me that it is a character vector. Therefore, I am a little confused on how to make it load into R correctly. Any advice would be helpful!
Thanks, Courtney