menu
Data

Datasets

Datasets represent a collection of timeseries which share a common schema, owner, and are generally subject to consistent entitlements. The easiest way to learn how to interact with datasets is to use the WEATHER example, which contains weather information for several major US cities from the National Weather Service. This dataset is available to all applications and does not need to be requested explicitly.

You can view and request available datasets from the Marquee Data Catalog.

Dataset Objects

All our datasets are either time-based (intraday) or date-based (daily). Datasets return fields that are categorized as either measures or dimensions:

  • Measures are facts that are usually quantities and that can be aggregated, such as tickers and exchanges
  • Dimensions describe or provide context to measures, like closing prices and volumes

If the data is a curve or surface, then the axes will usually be dimensions.

Date-based Datasets

Date-based datasets have date listed as a field in their data description. The following parameters are valid for queries to date-based datasets:

  • startDate (optional) - defaults to the end date minus a dataset-specific interval, which is currently 30 days
  • endDate (optional) - defaults to the current date
  • dates (optional) - used to return data from a specific set of dates

Time-based Datasets

Time-based datasets have time and updateTime listed as a field in their data description page. The following parameters are valid for queries to time-based datasets:

  • startTime (optional) - defaults to the end time minus a dataset-specific
  • interval - currently 24 hours for all real-time datasets
  • endTime (optional) - defaults to the current datetime
  • times (optional) - used to return data from a specific set of date times

Using Intervals

Time-based datasets can have very large number of observations over a given window (thousands per second). In order to interact with this data, our APIs provide the ability to down-sample data on our servers over given intervals. The intervals parameter allow you to get data which is evenly distributed in the specified number of intervals between the time or date range specified. Example:

from gs_quant.data import Dataset
from datetime import date

weather_ds = Dataset('WEATHER')
data_frame = weather_ds.get_data(date(2016, 1, 1),  date(2016, 1, 31), city=["Boston"], intervals=3)

print(data_frame)

Output:

     city        date  dewPoint  ...  snowfall                updateTime  windSpeed
0  Boston  2016-01-11      12.0  ...       0.0  2017-03-06T16:49:36.472Z       19.0
1  Boston  2016-01-21       7.0  ...       0.0  2017-03-06T16:49:36.473Z       13.6
2  Boston  2016-01-31      29.0  ...       0.0  2017-03-06T16:49:36.476Z       11.6

[3 rows x 10 columns]
info

Note

API responses are limited to approximately 100MB. If you receive a 400 Bad Request exception with the message "Number of rows returned... are more than maximum allowed", batch your query down into multiple, smaller queries.

Consider using smaller date / time ranges (adjust startTime and endTime or startDate and endDate as needed) or querying for fewer entities (e.g. asset ids, reports) each time.

Field Selection

If you want to ensure the response only contains the fields that you are interested in, you can use the fields parameters. In the weather dataset, say that you are only interested in maxTemperature and minTemperature. To only return these two fields, pass in the desired fields as arguments. Example:

from gs_quant.data import Dataset
from datetime import date

weather_ds = Dataset('WEATHER')
data_frame = weather_ds.get_data(date(2016, 1, 1), date(2016, 1, 2), city=["Boston"], fields=['maxTemperature', 'minTemperature'])

print(data_frame)

Output:

     city        date  maxTemperature  minTemperature
0  Boston  2016-01-01            41.0            33.0
1  Boston  2016-01-02            40.0            31.0

Related Content


GS DAP® is owned and operated by Goldman Sachs. This site is for informational purposes only and does not constitute an offer to provide, or the solicitation of an offer to provide access to or use of GS DAP®. Any subsequent commitment by Goldman Sachs to provide access to and / or use of GS DAP® would be subject to various conditions, including, amongst others, (i) satisfactory determination and legal review of the structure of any potential product or activity, (ii) receipt of all internal and external approvals (including potentially regulatory approvals); (iii) execution of any relevant documentation in a form satisfactory to Goldman Sachs; and (iv) completion of any relevant system / technology / platform build or adaptation required or desired to support the structure of any potential product or activity. All GS DAP® features may not be available in certain jurisdictions. Not all features of GS DAP® will apply to all use cases. Use of terms (e.g., "account") on GS DAP® are for convenience only and does not imply any regulatory or legal status by such term.
¹ Real-time data can be impacted by planned system maintenance, connectivity or availability issues stemming from related third-party service providers, or other intermittent or unplanned technology issues.
Transaction Banking services are offered by Goldman Sachs Bank USA (“GS Bank”) and its affiliates. GS Bank is a New York State chartered bank, a member of the Federal Reserve System and a Member FDIC. For additional information, please see Bank Regulatory Information.
Certain solutions and Institutional Services described herein are provided via our Marquee platform. The Marquee platform is for institutional and professional clients only. This site is for informational purposes only and does not constitute an offer to provide the Marquee platform services described, nor an offer to sell, or the solicitation of an offer to buy, any security. Some of the services and products described herein may not be available in certain jurisdictions or to certain types of clients. Please contact your Goldman Sachs sales representative with any questions. Any data or market information presented on the site is solely for illustrative purposes. There is no representation that any transaction can or could have been effected on such terms or at such prices. Please see https://www.goldmansachs.com/disclaimer/sec-div-disclaimers-for-electronic-comms.html for additional information.
Mosaic is a service mark of Goldman Sachs & Co. LLC. This service is made available in the United States by Goldman Sachs & Co. LLC and outside of the United States by Goldman Sachs International, or its local affiliates in accordance with applicable law and regulations. Goldman Sachs International and Goldman Sachs & Co. LLC are the distributors of the Goldman Sachs Funds. Depending upon the jurisdiction in which you are located, transactions in non-Goldman Sachs money market funds are affected by either Goldman Sachs & Co. LLC, a member of FINRA, SIPC and NYSE, or Goldman Sachs International. For additional information contact your Goldman Sachs representative. Goldman Sachs & Co. LLC, Goldman Sachs International, Goldman Sachs Liquidity Solutions, Goldman Sachs Asset Management, L.P., and the Goldman Sachs funds available through Goldman Sachs Liquidity Solutions and other affiliated entities, are under the common control of the Goldman Sachs Group, Inc.
© 2025 Goldman Sachs. All rights reserved.