Hi,
I have tripcolor trianulation plot wave plot and that plot i need to overlap with background as google map with zoom function , so i tried mplleaflet but the tripcolor plot is not coming over the map.
can you tell me how to do this.
%matplotlib inline
import matplotlib.pyplot as plt
from scipy.io import loadmat
import mplleaflet
import datetime
import pandas as pd
from dateutil.parser import parse
Hi, I have tripcolor trianulation plot wave plot and that plot i need to overlap with background as google map with zoom function , so i tried mplleaflet but the tripcolor plot is not coming over the map. can you tell me how to do this.
%matplotlib inline import matplotlib.pyplot as plt from scipy.io import loadmat import mplleaflet import datetime import pandas as pd from dateutil.parser import parse
import matplotlib as mpl
from pylab import *
import numpy as np import os
fig=plt.figure()
fig, ax = plt.subplots(figsize=(13, 13), subplot_kw=dict(projection=projection))
os.environ['PROJ_LIB'] = r'C:\Users\walps\Anaconda3\pkgs\proj4-5.2.0-ha925a31_1\Library\share'
from datetime import timedelta
import matplotlib.tri as mtri datamat = loadmat('IOEC_ECM2017_BC.mat') Xp = datamat['Xp'] Yp = datamat['Yp'] strt = datetime.datetime(2017, 1, 11, 0, 0) end = datetime.datetime(2017, 1, 21, 0, 0) numdays = 3
def perdelta(strt, end, delta): curr = strt while curr < end: yield curr curr += delta
Read element file
data = pd.read_table('fort.ele',delim_whitespace=True,names=('A','B','C','D'))
tri_new = pd.read_csv('fort.ele', delim_whitespace=True, names=('A', 'B', 'C', 'D'), usecols=[1, 2, 3], skiprows=1, dtype={'D': np.int})
data1=data[['B','C','D']]
tri=data1[1:]
dateList = [] for result in perdelta(strt, strt + timedelta(days=2), timedelta(hours=3)): dat = result
print(result)