bigquery-bigframes

Generates Python code using BigQuery DataFrames for pandas-style analysis and ML on BigQuery.

Updated Aug 11, 2026
One-click install
npx skills add https://github.com/Yashyasik/zexca-api --skill bigquery-bigframes-yashyasik
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: bigquery-bigframes
Source: https://github.com/Yashyasik/zexca-api/tree/main/.gemini/skills/bigquery-bigframes
Command: npx skills add https://github.com/Yashyasik/zexca-api --skill bigquery-bigframes-yashyasik

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Writing pandas-style data analysis and machine learning code against BigQuery requires knowing BigFrames-specific APIs, ordering modes, and ML packages that differ from standard pandas and scikit-learn, and mistakes cause slow queries or out-of-memory errors. ## Core Features & Use Cases - BigFrames DataFrame Best Practices: Enforces partial ordering mode, peek() previews, accessor-based transformations, and avoidance of local materialization via to_pandas(). - Serverless ML with BigQuery: Guides model training, evaluation, and prediction through bigframes.bigquery.ml instead of scikit-learn, with reference examples for linear and logistic regression. - Legacy BigFrames ML Support: Covers the legacy bigframes.ml package including ARIMA Plus forecasting, PCA, and model persistence with to_gbq(). - Use Case: In a notebook, ask for a logistic regression model trained on the public penguins dataset, and receive correct BigFrames code that trains directly in BigQuery without downloading data. ## Quick Start Write BigFrames code that loads the bigquery-public-data penguins table and trains a linear regression model to predict penguin body mass.

Frequently Asked Questions about bigquery-bigframes

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write pandas-style code that runs on BigQuery?▼

Use the BigFrames library by importing bigframes.pandas as bpd and calling familiar DataFrame methods that execute on BigQuery. Enable partial ordering mode with bpd.options.bigquery.ordering_mode = 'partial' right after import for faster processing.

BigFrames vs google-cloud-bigquery client library, which should I use?▼

BigFrames provides a pandas and scikit-learn-style DataFrame API for analysis and ML workflows, while google-cloud-bigquery is a SQL-first client library. Use BigFrames for dataframe-style work and the client library for SQL-first workflows.

Can I use scikit-learn with BigQuery DataFrames?▼

No, standard scikit-learn requires pulling data into local memory. Import ML tools from bigframes.bigquery.ml instead, which delegates training directly to BigQuery's scalable ML engine. The legacy bigframes.ml package is only for explicit requests.

Why does head() fail in BigFrames partial ordering mode?▼

head(n) requires strict row ordering, which partial ordering mode relaxes for performance. Use peek(n) instead, which randomly samples n rows and runs significantly faster, or explicitly sort the DataFrame before calling head().

When should I avoid to_pandas() in BigFrames?▼

Avoid to_pandas() whenever possible because it downloads all data to client memory, bypassing BigQuery's distributed computation and risking OOM errors. Only use it for small datasets, when an error explicitly requires it, or after aggregating data for plotting.