Here is the projection for these shapefiles in a proj4string format, as defined in https://www.fs.fed.us/nrs/atlas/littlefia/albers_prj.txt
'+proj=aea +lat_1=38 +lat_2=42 +lat_0=40 +lon_0=-82 +x_0=0 +y_0=0 +ellps=clrk66 +units=m +no_defs'
Here is the projection for these shapefiles in a proj4string format, as defined in https://www.fs.fed.us/nrs/atlas/littlefia/albers_prj.txt
'+proj=aea +lat_1=38 +lat_2=42 +lat_0=40 +lon_0=-82 +x_0=0 +y_0=0 +ellps=clrk66 +units=m +no_defs'
| > path.expand('~') | |
| [1] "C:/Users/shawntaylor/Documents" | |
| > normalizePath(path.expand('~')) | |
| [1] "C:\\Users\\shawntaylor\\Documents" | |
| > wd = getwd() | |
| > wd | |
| [1] "C:/Users/shawntaylor/Documents/portalPredictions" | |
| > path.expand(wd) | |
| [1] "C:/Users/shawntaylor/Documents/portalPredictions" | |
| > normalizePath(path.expand(wd)) |
| library(dplyr) | |
| library(tidyr) | |
| shrub_data<-read.csv("~/dplyrLesson/shrub_volume_experiment.csv") | |
| ######################## | |
| #some basics | |
| ####################### | |
| #ordering rows! | |
| #no more using shrub_data=shrub_data[order(shrub_data$site),] |
| #Use dplyr inside a function with arbitray column names | |
| #The dots stuff is from the internal workings of dplyr | |
| #Don't forget the _ at the end of the group by. | |
| #Other function also have the _ variation with the .dots argument available, | |
| #but when I first made this in early 2016 not all of them did. | |
| my_function=function(original_df, variables){ | |
| dots=lapply(variables, as.symbol) | |
| summarized_data = original_data %>% | |
| group_by_(.dots = dots ) %>% | |
| summarize(freq=sum(freq)) %>% |
| #Create a new file | |
| sudo fallocate -l 4G /swapfile | |
| #RW for root only | |
| sudo chmod 600 /swapfile | |
| sudo mkswap /swapfile | |
| sudo swapon /swapfile | |
| #check swap |
| prior_version = 3.3 | |
| library_path = .libPaths()[1] | |
| library_path = substr(library_path, 1, nchar(library_path)-3) | |
| old_library_path=paste0(library_path, prior_version) | |
| old_packages = list.files(old_library_path) | |
| install.packages(old_packages) |