'Data structure with multiple keys in python

I have a timeseries based data set with multiple keys - up to 5 (e.g.LocationCategory, SizeCategory, ClimateCategory) and corresponding values - up to 10 (e.g.Temperature, Humidity, SunlightHoursperDay).

The total raw data corresponds to around 1 GB. For my analysis I quickly want to query the values based on the different keys (sometimes only by one, sometimes by multiple). I know databases are the ideal situation for this, however I want to share this data and python script with people who might not be connected to a network. Hence, I would like to have a local implementation of the data structure in python.

WeatherDataPointCollection[Location]
WeatherDataPointCollection[Location, Size, Climate]

A datapoint would look something like:

class WeatherDataPoint: 
   ''' should have a unique key set of Location, Size, Climate '''
   Temperature = 12
   Humidity = 42
   Sunlight = 0.49

I need help bringing the two things together, i.e. getting all WeatherDataPoints that match the above key(s) specifications.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source