(C-x means ctrl+x, M-x means alt+x)
The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf
:
#Boundless Geo Exercise 11 ##What neighborhood and borough is Atlantic Commons in? Solution:
SELECT name, boroname
FROM nyc_neighborhoods
WHERE ST_Intersects(
the_geom,(SELECT the_geom FROM nyc_streets WHERE name = 'Atlantic Commons'))
{ | |
"version": "0.0.1", | |
"name": "namedmap_tutorial_14", | |
"auth": { | |
"method": "open" | |
}, | |
"layergroup": { | |
"layers": [{ | |
"type": "torque", | |
"options": { |
SELECT
cartodb_id,
the_geom,
abbrev, name, postal
FROM ne_50m_admin_1_states
WHERE postal NOT IN ('AK', 'HI')
UNION
# Often when reading in a ShapeFile from Basemap, you'll get: "ValueError: readshapefile can only handle 2D shape types" | |
# A trick can be to convert your geometry in your GeoPandas Dataframe and restoring the new flattened 2D geometry | |
# series back into a shapefile and try again. | |
# edit from http://stackoverflow.com/questions/33417764/basemap-readshapefile-valueerror | |
from shapely.geometry import Polygon, MultiPolygon, shape, Point | |
import geopandas as gp | |
def convert_3D_2D(geometry): | |
''' |
""" | |
Main Steps: | |
1. Create blob for each file | |
2. Create tree with the blobs on top of the specific branch | |
3. Commit the tree | |
4. Update the branch to point to the new commit | |
""" | |
import os |