Data inspection

Satellite data

You can plot the MSG satellite data via:

satellite_data.IR_108.plot(cmap="Greys",vmin=210,vmax=310,figsize=(16,10))
<matplotlib.collections.QuadMesh at 0x7efc84e75090>
../../../_images/02_inspection_3_1.png

Or, to be more flexible, you can use the matplotlib library to generate composites:

import numpy as np

# Helper function to normalize array to range 0-1 (with clips at lower and upper percentiles (1% - 99%))
def normArray(x):
    lp = 1
    up = 99
    x = np.clip(x, np.nanpercentile(x, lp), np.nanpercentile(x, up))
    x = (x - np.nanmin(x)) / (np.nanmax(x) - np.nanmin(x))
    return x
import matplotlib.pyplot as plt

red = normArray(satellite_data.IR_039[0]*-1)
green = normArray(satellite_data.IR_108[0]*-1)
blue = normArray(satellite_data.IR_120[0]*-1)

fig, ax = plt.subplots(1,1,figsize=(10,8))
im = ax.imshow(np.array([red,green,blue]).transpose(1,2,0))
ax.set_title("Exemplary MSG scene (IR overview)")
fig.tight_layout()
plt.show()
../../../_images/02_inspection_6_0.png
dem.plot(vmin=0,vmax=3000,cmap="terrain",figsize=(12,8))
<matplotlib.collections.QuadMesh at 0x7efc7db9e1d0>
../../../_images/02_inspection_9_1.png

Station data

You can plot the METAR station distribution using pandas’ built-in plotting functions:

station_meta_data.plot.scatter(x="x",y="y",label="METAR stations",figsize=(12,8))
<AxesSubplot:xlabel='x', ylabel='y'>
../../../_images/02_inspection_11_1.png

Task

  • Visualize the data sets to get a better overview of their characteristics

  • Which satellite bands, do you think, will help detect clouds? Which don’t?