mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-12 13:32:39 +02:00
maps import
This commit is contained in:
parent
f6228abd4c
commit
adce78ba5a
1 changed files with 4 additions and 3 deletions
|
|
@ -4,7 +4,6 @@ import matplotlib.patches as patches
|
||||||
from matplotlib.patches import Polygon
|
from matplotlib.patches import Polygon
|
||||||
from matplotlib.collections import PatchCollection
|
from matplotlib.collections import PatchCollection
|
||||||
#from matplotlib import cm
|
#from matplotlib import cm
|
||||||
import shapefile
|
|
||||||
import re
|
import re
|
||||||
|
|
||||||
pb.ion()
|
pb.ion()
|
||||||
|
|
@ -134,8 +133,10 @@ def plot_string_match(sf,regex,field,**kwargs):
|
||||||
plot(shape_records,**kwargs)
|
plot(shape_records,**kwargs)
|
||||||
|
|
||||||
|
|
||||||
def new_shape_string(sf,name,regex,field=2,type=shapefile.POINT):
|
def new_shape_string(sf,name,regex,field=2,type=None):
|
||||||
|
import shapefile
|
||||||
|
if type is None:
|
||||||
|
type = shapefile.POINT
|
||||||
newshp = shapefile.Writer(shapeType = sf.shapeType)
|
newshp = shapefile.Writer(shapeType = sf.shapeType)
|
||||||
newshp.autoBalance = 1
|
newshp.autoBalance = 1
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue