I would like to get only the first match if key is in dict. Else I would like to get a NaN. I'm struggling with the correct syntax to fit my needs. The match doesn't have to be in a list, I just need the number. I tried tons of variations...:
'Temperatur':[d2.get(key) for key in temperatur if key in d2][0] else None
'Temperatur':d2.get(key) for key in temperatur if key in d2 else None