Skip to content

Commit 5bebff4

Browse files
committed
DOC: Pass static_stability in QVector example
Helps make clear that this is an option for this calculation. Addresses part of #3689.
1 parent 407eb0d commit 5bebff4

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

examples/calculations/QVector.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,10 @@
2323
# Calculate the temperature advection of the flow
2424
tadv = mpcalc.advection(ds.temperature, ds.uwind, ds.vwind)
2525

26-
# Calculate the q-vectors
27-
u_qvect, v_qvect = mpcalc.q_vector(ds.uwind, ds.vwind, ds.temperature, 850 * units.hPa)
26+
# Calculate the q-vectors. Passing in a fixed value of static stability, but could also
27+
# use `mpcalc.static_stability()`.
28+
u_qvect, v_qvect = mpcalc.q_vector(ds.uwind, ds.vwind, ds.temperature, 850 * units.hPa,
29+
static_stability=0.02 * units('J / kg / Pa^2'))
2830

2931
# start figure and set axis
3032
fig, ax = plt.subplots(figsize=(5, 5))

0 commit comments

Comments
 (0)