pvlib.iotools.read_midc#
- pvlib.iotools.read_midc(filename, variable_map={}, raw_data=False, **kwargs)[source]#
- Read in National Renewable Energy Laboratory Measurement and Instrumentation Data Center weather data. The MIDC is described in [1]. - Parameters:
- filename (string or file-like object) – Filename, url, or file-like object of data to read. 
- variable_map (dictionary) – Dictionary for mapping MIDC field names to pvlib names. Used to rename the columns of the resulting DataFrame. Does not map names by default. See Notes for an example. 
- raw_data (boolean) – Set to true to use format_index_raw to correctly format the date/time columns of MIDC raw data files. 
- kwargs (dict) – Additional keyword arguments to pass to pandas.read_csv 
 
- Returns:
- data (Dataframe) – A dataframe with DatetimeIndex localized to the provided timezone. 
 - Notes - The variable_map argument should map fields from MIDC data to pvlib names. - E.g. if a MIDC file contains the variable ‘Global Horizontal [W/m^2]’, passing the dictionary below will rename the column to ‘ghi’ in the returned Dataframe. - {‘Global Horizontal [W/m^2]’: ‘ghi’} - See the MIDC_VARIABLE_MAP for collection of mappings by site. For a full list of pvlib variable names see the Nomenclature. - Be sure to check the units for the variables you will use on the MIDC site. - References 
