Symbols and Key Fields
The symbol parameter serves as the key for querying datasets in CloudQuant Data Liberator. While the platform initially focused on US Equity Symbols, its datasets have expanded to include diverse data types (shipping, weather, market research) with varied keys like zip codes and geographic locations. The developers maintained the symbol parameter for consistency with existing users.
Default Value: None (returns all symbols/keys, including blanks/NaN values)
When setting your query parameters, consider the amount of data you may be requesting and start small until you understand data volume patterns for each symbol/date combination.
Determining Unique Symbols in a Dataset
The most straightforward approach is to query and count the data. Here is an example using the daily_bars dataset:
df = liberator.get_dataframe(liberator.query(
name = 'daily_bars',
as_of = '2024-07-24',
back_to = '2024-07-22',
symbols = None))
df
This returns over 20,000 rows. To count unique symbols:
len(df.symbol.unique())
# Output: 10524
Storing and Displaying Symbols
To store symbols in a variable:
allsym = list(df.symbol.unique())
To display the complete list (with caution — lists can be lengthy):
print(list(df.symbol.unique()))
Query Methods for All Symbols
Either explicitly set symbols = None or omit the parameter entirely, as it defaults to None.