Skip to content

Instantly share code, notes, and snippets.

View transit_ridership_per_capita_538.csv
urban area population trips_per_cap
New York--Newark, NY--NJ--CT 18,617,730 229.8
San Francisco--Oakland, CA 3,368,743 131.5
Washington, DC-VA-MD 4,782,117 99.6
Athens--Clarke County, GA 128,615 99.5
Boston, MA-NH-RI 4,261,138 94.3
Urban Honolulu, HI 820,535 88.4
Champaign, IL 144,685 87.4
State College, PA 87,702 85
Chicago, IL-IN 8,666,409 74.7
@tbuckl
tbuckl / st_transform_an_environment.R
Created Oct 31, 2018
st_transform a list of simple features dataframes to one coordinate reference system in R
View st_transform_an_environment.R
library(sf)
sf_dfs <- ls()[sapply(mget(ls(), .GlobalEnv), function(x) {class(x)[[1]]=="sf"})]
sf_dfs_list <- lapply(sf_dfs,get)
e <- eapply(environment(), st_transform, crs=26910)
View duke_lines_gtfs.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@tbuckl
tbuckl / fill_line_holes.r
Last active May 29, 2018
a failed attempt to fill spaces between multilinestrings
View fill_line_holes.r
library(DBI)
library(RPostgreSQL)
library(sf)
library(dplyr)
library(readxl)
library(jsonlite)
congested_segments_file <- "data/WeekdayCongestedSegmentsList_2017_v2.xlsx"
database_credentials_file <- "~/credentials/tbuckley_gisdb3.json"
View se_top_50_tagged.csv
question_title tool_classification
Measuring accuracy of latitude and longitude? Wikipedia / GeoJSON Data Model
Does Y mean latitude and X mean longitude in every GIS software? Wikipedia
What is the difference between Vector and Raster data models? Wikipedia
Calculating longitude length in miles? geosphere
Display a local file in Google Maps Mapview
Adding Basemaps from Google or Bing in QGIS? Mapview
What ratio scales do Google Maps zoom levels correspond to? google maps
Export list of values into csv or txt file export from gis files
Merging multiple vector layers to one layer using QGIS? Merge/sf
View top_50_stats_questions_by_views.csv
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 3.
Title,Post Link,Id,Score,ViewCount,Body
"What is the difference between discrete data and continuous data?","{
""id"": 206,
""title"": ""What is the difference between discrete data and continuous data?""
}","206","47","635826","<p>What is the difference between discrete data and continuous data?</p>
"
"How to normalize data to 0-1 range?","{
""id"": 70801,
""title"": ""How to normalize data to 0-1 range?""
}","70801","184","633404","<p>I am lost in normalizing, could anyone guide me please.</p>
View top_50_gis_queries_by_views_stackexchange.csv
Title Post Link Id Score ViewCount Body
Measuring accuracy of latitude and longitude? { "id": 8650, "title": "Measuring accuracy of latitude and longitude?" } 8650 323 283565 <p>I have latitude and longitude as <code>19.0649070739746</code> and <code>73.1308670043945</code> respectively. </p> <p>In this case both coordinates are <code>13</code> decimal places long, but sometimes I also get coordinates which are <code>6</code> decimal places long. </p> <p>Do fewer decimal points affect accuracy, and what does every digit after the decimal place signify?</p>
View san_ramon_livermore_sample_bbox.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View downtown_alameda.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.