How can I calculate the "stability state" of air from a given set of data?
You should calculate the environmental lapse rate (ELR), not use a fixed value. In the table you presented, the ELR is:
$$ \frac{T_{alt_1} - T_{alt_2}}{alt_2-alt_1} \cdot 1000$$
Compare this calculated value to dry and moist (or saturated) adiabatic lapse rates.

If the value falls between them, the air is conditionally unstable.
If the value is larger than the dry adiabatic lapse rate, the air is
absolutely unstable.

For accurate results, you must calculate SALR, as it varies strongly with altitude. Formula is in Wikipedia article.
See Wikipedia: Lapse rate and  Skybrary: Lapse Rate for more in-depth explanation.
Caveat, the aforementioned sites explain absolute unstability differently, I have no recolletion which it actually is, and my study books are buried in the garage...