PoolingClient
The PoolingClient object used for fetching information through different API calls, each with different parameters.
Attributes
queries
The list of queries to-be-executed.
Note: There is nothing to guarantee that the fetched participants via this object don't have duplicates. It's up to you to use this data and infer from it at your own risk.
Example:
Query 1: Participants whose companies work on B2B solutions and have a cs degree.
Query 2: Females who work in front-end and have a cs degree.
Among these 2 queries, a female could fulfill both sets of criteria. The wrapper doesn't currently implement safeguards to prevent duplicates in query results.
Methods
get_df()
get_df()
Returns a pandas.DataFrame
instance of the aggregated participant data from the queries.
Parameters
No parameters
Returns
save_csv(filename: str)
save_csv(filename: str)
Parameters
filename
str
The name of the .csv
file to dump the fetched participant data in (without extension). No extension is needed explicitly as it's added during the file-saving process.
"my_awesome_data"
Returns
None
This method is simply a placeholder for the pandas.DataFrame.to_csv()
method. It simply saves the generated pandas.DataFrame instance to a .csv
file and excludes the index. You can customize your own function parameters for this by simply calling the get_df()
method, and manipulating the resulting pandas.DataFrame as you want.
save_excel(filename: str)
save_excel(filename: str)
Parameters
filename
str
The name of the .xlsx
file to dump the fetched participant data in (without extension). No extension is needed explicitly as it's added during the file-saving process.
"my_awesome_data"
Returns
None
This method is simply a placeholder for the pandas.DataFrame.to_excel()
method. It simply saves the generated pandas.DataFrame instance to a .xlsx
file and excludes the index. You can customize your own function parameters for this by simply calling the get_df()
method, and manipulating the resulting pandas.DataFrame as you want.
This function uses "xlsxwriter"
as the excel writer engine by default. Customization is available by calling to_excel()
on a pandas.DataFrame instance instead.
Last updated