forked from NOAA-PMEL/osmc_dashboard
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathReport.py
58 lines (30 loc) · 1.04 KB
/
Report.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#!/usr/bin/env python
# coding: utf-8
# In[45]:
import pandas as pd
import numpy as np
# In[46]:
depth = pd.read_pickle('depth_data_latest.pkl')
surface = pd.read_pickle('surface_data_latest.pkl')
depth_locs = pd.read_pickle('depth_locations_latest.pkl')
surface_locs = pd.read_pickle('surface_locations_latest.pkl')
# In[47]:
dnames = list(depth['platform_type'].unique())
snames = list(surface['platform_type'].unique())
names = dnames + snames
print("\nAll platform types reporting:\n")
all = sorted(set(names))
print(*all, sep='\n')
# In[48]:
print("\nNumber of Depth Platforms:\n")
# In[49]:
counts = depth_locs['platform_type'].value_counts()
print(counts.to_string())
# In[50]:
print('\nNumber of Surface Platforms:\n')
scounts = surface_locs['platform_type'].value_counts()
print(scounts.to_string())
# In[55]:
print("\nNumber of Observations:")
print("\nDepth Platforms:\t" + format(depth.shape[0],',d'))
print("Surface Platforms:\t" + format(surface.shape[0],',d'))