MCPcopy Index your code
hub / github.com/plotly/plotly.py / election

Function election

plotly/data/__init__.py:162–178  ·  view source on GitHub ↗

Each row represents voting results for an electoral district in the 2013 Montreal mayoral election. Parameters ---------- return_type: {'pandas', 'polars', 'pyarrow', 'modin', 'cudf'} Type of the resulting dataframe Returns ------- Dataframe of `return_type

(return_type="pandas")

Source from the content-addressed store, hash-verified

160
161
162def election(return_type="pandas"):
163 """
164 Each row represents voting results for an electoral district in the 2013 Montreal
165 mayoral election.
166
167 Parameters
168 ----------
169 return_type: {'pandas', 'polars', 'pyarrow', 'modin', 'cudf'}
170 Type of the resulting dataframe
171
172 Returns
173 -------
174 Dataframe of `return_type` type
175 Dataframe with 58 rows and the following columns:
176 `['district', 'Coderre', 'Bergeron', 'Joly', 'total', 'winner', 'result', 'district_id']`.
177 """
178 return _get_dataset("election", return_type=return_type)
179
180
181def election_geojson():

Callers

nothing calls this directly

Calls 1

_get_datasetFunction · 0.85

Tested by

no test coverage detected