content
large_stringlengths
3
20.5k
url
large_stringlengths
53
192
branch
large_stringclasses
4 values
source
large_stringclasses
51 values
embeddings
listlengths
384
384
score
float64
-0.21
0.65
# FAQ & Troubleshooting Quick answers and fixes for the most common questions and issues. --- ## Frequently Asked Questions ### What LLM providers work with Hermes? Hermes Agent works with any OpenAI-compatible API. Supported providers include: - \*\*[OpenRouter](https://openrouter.ai/)\*\* — access hundreds of models ...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ -0.05158637836575508, -0.046596426516771317, -0.03800424933433533, -0.052816472947597504, 0.0216454416513443, -0.10284429788589478, -0.08238083124160767, -0.013754240237176418, -0.010681265033781528, -0.0013919740449637175, 0.0005009068991057575, 0.0007013996946625412, 0.034228354692459106, ...
0.072722
See the [Configuration guide](../user-guide/configuration.md) for details. :::tip Ollama users If you set a custom `num\_ctx` in Ollama (e.g., `ollama run --num\_ctx 64000`), make sure to set the matching context length in Hermes — Ollama's `/api/show` reports the model's \*maximum\* context, not the effective `num\_ct...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ 0.009905165992677212, 0.024189602583646774, -0.014878448098897934, -0.016690567135810852, -0.0015778598608449101, -0.11569757014513016, -0.08394400775432587, -0.036393649876117706, 0.030306220054626465, 0.002261863322928548, -0.00527251698076725, -0.01234650518745184, -0.01099491212517023, ...
0.076449
nvm init (works regardless of shell) - /etc/profile.d/cargo.sh # system-wide rc files # When this list is set, the default ~/.bashrc auto-source is NOT added — # include it explicitly if you want both: # - ~/.bashrc # - ~/.zshrc ``` Missing files are skipped silently. Sourcing happens in bash, so files that rely on zsh...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ 0.0031416891142725945, 0.05500176548957825, -0.026810063049197197, -0.005293760448694229, 0.06696280092000961, 0.04388828203082085, 0.0009538221056573093, 0.023706763982772827, 0.001968247350305319, 0.0010540506336838007, 0.020228534936904907, -0.07764096558094025, 0.04918622970581055, 0.0...
-0.045273
context window hermes chat --model openrouter/google/gemini-3-flash-preview ``` If this happens on the first long conversation, Hermes may have the wrong context length for your model. Check what it detected: Look at the CLI startup line — it shows the detected context length (e.g., `📊 Context limit: 128000 tokens`). ...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ 0.00444159796461463, -0.06254228204488754, 0.020376041531562805, -0.03649386763572693, 0.026781391352415085, -0.11182859539985657, -0.04382928088307381, -0.009677453897893429, 0.09526244550943375, -0.008131573908030987, -0.011114755645394325, 0.00005302319550537504, -0.041919101029634476, ...
-0.00337
when enabled, services may not survive WSL restarts or Windows idle shutdowns. \*\*Solution:\*\* Use foreground mode instead of the systemd service: ```bash # Option 1: Direct foreground (simplest) hermes gateway run # Option 2: Persistent via tmux (survives terminal close) tmux new -s hermes 'hermes gateway run' # Rea...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ 0.013940312899649143, -0.0032737422734498978, -0.05051562190055847, 0.001709268311969936, 0.009755722247064114, -0.025312215089797974, -0.05107095092535019, 0.03343090042471886, 0.09051607549190521, 0.03699731081724167, -0.056405749171972275, 0.04919741675257683, 0.023581180721521378, 0.05...
0.000014
connection errors - Ensure the server responds to the `tools/list` RPC method - Review any `tools.include`, `tools.exclude`, `tools.resources`, `tools.prompts`, or `enabled` settings under that server - Remember that resource/prompt utility tools are only registered when the session actually supports those capabilities...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ 0.010737573727965355, -0.020205948501825333, 0.036260660737752914, -0.009671666659414768, 0.0058213695883750916, -0.041388534009456635, -0.06343197077512741, -0.03540327027440071, -0.022855516523122787, 0.06535997241735458, 0.016173148527741432, -0.016665451228618622, 0.029437482357025146, ...
0.041188
You can also be explicit in your prompt: \*"Delegate a task to write social media posts about our product launch. Use your subagent for the actual writing."\* The agent will use `delegate\_task`, which automatically picks up the delegation config. For one-off model switches without delegation, use `/model` in the CLI: ...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ -0.06332384794950485, -0.0842168927192688, -0.03783218190073967, -0.03263844549655914, 0.03114822320640087, -0.07354968041181564, 0.04610956460237503, 0.026721836999058723, 0.02346131019294262, -0.0016821625176817179, -0.013577158562839031, 0.0039514219388365746, 0.03799913451075554, 0.049...
-0.047148
payload size limits. If skills aren't appearing, it may be a total payload size issue rather than the 100 command count limit — disabling unused skills helps with both. ::: ### Shared thread sessions (multiple users, one conversation) \*\*Scenario:\*\* You have a Telegram or Discord thread where multiple people mention...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ -0.041741885244846344, -0.030181098729372025, 0.014068130403757095, -0.035352107137441635, -0.0466514490544796, -0.05738004669547081, 0.08685074001550674, -0.004497373476624489, 0.03549777343869209, 0.03037106618285179, -0.02861330471932888, -0.08758103847503662, 0.03568391129374504, 0.062...
0.119875
gives a permission denied error. \*\*Cause:\*\* This usually happens when `~/.zshrc` (or `~/.bashrc`) has incorrect file permissions, or when the installer couldn't write to it cleanly. It's not a Hermes-specific issue — it's a shell config permissions problem. \*\*Solution:\*\* ```bash # Check permissions ls -la ~/.zs...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/faq.md
main
hermes-agent
[ 0.032752346247434616, -0.004832460079342127, -0.023415708914399147, -0.058408211916685104, 0.03785485774278641, -0.07158338278532028, -0.027773449197411537, 0.015937456861138344, 0.009376151487231255, 0.031177112832665443, -0.0056956615298986435, -0.08010013401508331, 0.08942817896604538, ...
-0.122398
# Toolsets Reference Toolsets are named bundles of tools that control what the agent can do. They're the primary mechanism for configuring tool availability per platform, per session, or per task. ## How Toolsets Work Every tool belongs to exactly one toolset. When you enable a toolset, all tools in that bundle become ...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/toolsets-reference.md
main
hermes-agent
[ -0.052011288702487946, -0.051442671567201614, -0.08487164229154587, -0.02015511319041252, 0.003043281612917781, -0.054366614669561386, 0.06408168375492096, 0.038020599633455276, 0.03295420482754707, -0.002115273382514715, 0.035957787185907364, -0.0326358787715435, 0.02705530822277069, -0.0...
0.156991
for text-to-video. | | `kanban` | `kanban\_block`, `kanban\_comment`, `kanban\_complete`, `kanban\_create`, `kanban\_heartbeat`, `kanban\_link`, `kanban\_list`, `kanban\_show`, `kanban\_unblock` | Multi-agent coordination tools. Registered for dispatcher-spawned task workers (`HERMES\_KANBAN\_TASK`) and for profiles th...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/toolsets-reference.md
main
hermes-agent
[ -0.005744988098740578, -0.09325747191905975, -0.04457532986998558, 0.01200475450605154, 0.002539707813411951, -0.024304382503032684, 0.041430070996284485, 0.009878912940621376, -0.025879384949803352, -0.001639567082747817, 0.058148398995399475, -0.08203691989183426, 0.02064925618469715, 0....
0.192971
| | `hermes-qqbot` | Same as `hermes-cli`. | | `hermes-wecom` | Same as `hermes-cli`. | | `hermes-wecom-callback` | Same as `hermes-cli`. | | `hermes-weixin` | Same as `hermes-cli`. | | `hermes-yuanbao` | Adds the five `yb\_\*` tools (DM/group/sticker) on top of `hermes-cli`. | | `hermes-homeassistant` | Same as `herme...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/toolsets-reference.md
main
hermes-agent
[ -0.062150757759809494, -0.05202026292681694, -0.011258832179009914, -0.014109302312135696, -0.049344751983881, -0.02170035056769848, -0.012059750035405159, -0.0377027653157711, -0.011318842880427837, 0.006210325285792351, 0.0393049493432045, -0.04500977694988251, 0.057472873479127884, -0.0...
0.098414
# Bundled Skills Catalog Hermes ships with a large built-in skill library copied into `~/.hermes/skills/` on install. Each skill below links to a dedicated page with its full definition, setup, and usage. Hermes also syncs bundled skills on `hermes update`, but the sync manifest respects local deletions and user edits....
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/skills-catalog.md
main
hermes-agent
[ -0.10728032886981964, -0.030984481796622276, -0.003612932050600648, 0.028482744470238686, -0.00574952969327569, -0.011396389454603195, -0.007492460310459137, -0.0601213164627552, -0.07813266664743423, -0.02411569468677044, 0.09458482265472412, 0.0459807924926281, 0.03744792938232422, -0.00...
0.050563
browser demos with @chenglou/pretext — DOM-free text layout for ASCII art, typographic flow around obstacles, text-as-geometry games, kinetic typography, and text-powered generative art. Produces single-file HT... | `creative/pretext` | | [`sketch`](/docs/user-guide/skills/bundled/creative/creative-sketch) | Throwaway ...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/skills-catalog.md
main
hermes-agent
[ -0.05721345171332359, -0.03734961524605751, 0.05020403861999512, -0.016642993316054344, 0.06788793206214905, -0.015241440385580063, 0.045224759727716446, 0.046329714357852936, -0.012094782665371895, 0.008217522874474525, 0.05020856484770775, -0.015891794115304947, 0.01845838502049446, -0.0...
0.154474
| lm-eval-harness: benchmark LLMs (MMLU, GSM8K, etc.). | `mlops/evaluation/lm-evaluation-harness` | | [`obliteratus`](/docs/user-guide/skills/bundled/mlops/mlops-inference-obliteratus) | OBLITERATUS: abliterate LLM refusals (diff-in-means). | `mlops/inference/obliteratus` | | [`segment-anything-model`](/docs/user-guide...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/skills-catalog.md
main
hermes-agent
[ -0.007447159383445978, -0.0367639884352684, -0.0028809437062591314, 0.013766585849225521, 0.08997782319784164, -0.09180258214473724, -0.029542770236730576, -0.001873259898275137, -0.011828211136162281, -0.024849211797118187, 0.031327985227108, -0.07727590203285217, -0.011626532301306725, -...
0.13489
fixing. | `software-development/systematic-debugging` | | [`test-driven-development`](/docs/user-guide/skills/bundled/software-development/software-development-test-driven-development) | TDD: enforce RED-GREEN-REFACTOR, tests before code. | `software-development/test-driven-development` | | [`writing-plans`](/docs/user...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/skills-catalog.md
main
hermes-agent
[ -0.039712365716695786, 0.04335329309105873, -0.01540036778897047, 0.03799619898200035, 0.06756594777107239, 0.0018135338323190808, 0.03910985589027405, 0.0495963953435421, -0.11463681608438492, 0.026022326201200485, 0.04797656834125519, -0.07297693938016891, 0.038177795708179474, -0.031288...
0.04772
# Built-in Tools Reference This page documents Hermes' built-in tools, grouped by toolset. Availability varies by platform, credentials, and enabled toolsets. \*\*Quick counts (current registry):\*\* ~64 tools — 10 browser tools (core) + 2 CDP-gated browser tools, 4 file tools, 4 Home Assistant tools, 2 terminal tools,...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/tools-reference.md
main
hermes-agent
[ -0.021860908716917038, -0.08898110687732697, -0.055469974875450134, 0.051529914140701294, -0.017453985288739204, -0.03564375638961792, 0.02076650597155094, 0.014927501790225506, -0.008283154107630253, 0.013769946061074734, 0.0476151667535305, -0.044613324105739594, 0.03612590581178665, -0....
0.220067
Requires environment | |------|-------------|----------------------| | `browser\_cdp` | Send a raw Chrome DevTools Protocol command. Escape hatch for browser operations not covered by the higher-level `browser\_\*` tools. See https://chromedevtools.github.io/devtools-protocol/ | CDP endpoint | | `browser\_dialog` | Res...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/tools-reference.md
main
hermes-agent
[ -0.04494881257414818, -0.000569250201806426, 0.01911776326596737, 0.0054150293581187725, 0.021476836875081062, -0.12383794784545898, -0.03767699748277664, 0.0148936677724123, 0.031023001298308372, -0.03294267877936363, -0.03234908729791641, -0.08304829895496368, -0.06513528525829315, 0.020...
0.013384
file contents or find files by name. Use this instead of grep/rg/find/ls in terminal. Ripgrep-backed, faster than shell equivalents. Content search (target='content'): Regex search inside files. Output modes: full matches with line… | — | | `write\_file` | Write content to a file, completely replacing existing content....
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/tools-reference.md
main
hermes-agent
[ -0.03968009725213051, 0.02664433792233467, -0.031586576253175735, -0.00975610502064228, 0.07382269948720932, -0.005153094418346882, 0.02104773372411728, 0.058961618691682816, -0.039384882897138596, 0.04530304670333862, 0.056336659938097, -0.04161998629570007, 0.013885418884456158, -0.04609...
-0.007901
a comment to the task thread without changing its state — useful for surfacing intermediate findings. | `HERMES\_KANBAN\_TASK` or `kanban` toolset | | `kanban\_create` | Fan out child tasks from the current task. Used by orchestrators and follow-up-spawning workers. | `HERMES\_KANBAN\_TASK` or `kanban` toolset | | `kan...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/tools-reference.md
main
hermes-agent
[ -0.034632619470357895, -0.046449270099401474, -0.008591617457568645, 0.07943297177553177, -0.0064363982528448105, -0.006101613398641348, -0.0019348552450537682, 0.0016305185854434967, -0.0014815630856901407, 0.09053968638181686, 0.022078629583120346, -0.045126330107450485, -0.023995423689484...
0.153952
the user provides multiple tasks. Call with no parameters to read the current list. Writing: - Provide 'todos' array to create/update items - merge=… | — | ## `vision` toolset | Tool | Description | Requires environment | |------|-------------|----------------------| | `vision\_analyze` | Analyze images using AI vision...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/tools-reference.md
main
hermes-agent
[ -0.015048930421471596, -0.01707487553358078, -0.0412060022354126, 0.0008917561499401927, 0.04144462198019028, -0.07421404123306274, 0.02995825558900833, 0.07562973350286484, 0.01676926761865616, -0.02877008356153965, 0.01757645606994629, -0.10453318059444427, 0.011593145318329334, 0.055066...
0.126469
are configured (check\_fn-gated). | XAI\_API\_KEY \*\*or\*\* xAI Grok OAuth (SuperGrok / Premium+) login | ## `tts` toolset | Tool | Description | Requires environment | |------|-------------|----------------------| | `text\_to\_speech` | Convert text to speech audio. Returns a MEDIA: path that the platform delivers as...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/tools-reference.md
main
hermes-agent
[ -0.06883904337882996, -0.051405131816864014, -0.045291658490896225, -0.07456880807876587, 0.010968138463795185, -0.08698522299528122, 0.04210425540804863, -0.015984393656253815, 0.06666867434978485, -0.0536203607916832, 0.046635694801807404, -0.07273377478122711, -0.009997515007853508, 0.0...
0.151273
# MCP Config Reference This page is the compact reference companion to the main MCP docs. For conceptual guidance, see: - [MCP (Model Context Protocol)](/user-guide/features/mcp) - [Use MCP with Hermes](/guides/use-mcp-with-hermes) ## Root config shape ```yaml mcp\_servers: : command: "..." # stdio servers args: [] env...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/mcp-config-reference.md
main
hermes-agent
[ -0.06863061338663101, 0.008234496228396893, 0.0008702540653757751, -0.03466195613145828, -0.02814589999616146, -0.08129231631755829, -0.05146853253245354, 0.020704297348856926, 0.0217115618288517, 0.015193712897598743, 0.06018805503845215, -0.014228669926524162, 0.09904278814792633, -0.038...
0.038943
when `resources: true` or `prompts: true`, Hermes only registers those utility tools if the MCP session actually exposes the corresponding capability. So this is normal: - you enable prompts - but no prompt utilities appear - because the server does not support prompts ## `enabled: false` ```yaml mcp\_servers: legacy: ...
https://github.com/NousResearch/hermes-agent/blob/main/website/docs/reference/mcp-config-reference.md
main
hermes-agent
[ 0.012993133626878262, -0.020138004794716835, -0.0068140896037220955, -0.014748900197446346, 0.021198397502303123, -0.06894078105688095, -0.042081933468580246, -0.060201361775398254, 0.020800206810235977, 0.04178442806005478, 0.019612999632954597, -0.04705873876810074, 0.062377721071243286, ...
0.051326
.. \_sparse: {{ header }} \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Sparse data structures \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* pandas provides data structures for efficiently storing sparse data. These are not necessarily sparse in the typical "mostly 0". Rather, you can view these objects as being "compres...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/sparse.rst
main
pandas
[ -0.07209879159927368, 0.004367179237306118, -0.058042995631694794, 0.022824754938483238, 0.02321712113916874, -0.137265145778656, 0.05192553997039795, -0.04962867125868797, 0.012475020252168179, -0.019505305215716362, 0.01864073984324932, 0.009881979785859585, -0.023987019434571266, -0.009...
0.052569
python dense = pd.DataFrame({"A": [1, 0, 0, 1]}) dtype = pd.SparseDtype(int, fill\_value=0) dense.astype(dtype) .. \_sparse.scipysparse: Interaction with \*scipy.sparse\* ------------------------------- Use :meth:`DataFrame.sparse.from\_spmatrix` to create a :class:`DataFrame` with sparse values from a sparse matrix. ....
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/sparse.rst
main
pandas
[ -0.01875877007842064, -0.06258878856897354, -0.12369231134653091, -0.03526323288679123, 0.014221134595572948, -0.06611096858978271, 0.010928901843726635, -0.047408327460289, -0.05840260908007622, -0.010152939707040787, -0.011944008991122246, 0.0010829485254362226, -0.003285651095211506, 0....
-0.02031
{{ header }} .. \_user\_guide: ========== User Guide ========== The User Guide covers all of pandas by topic area. Each of the subsections introduces a topic (such as "working with missing data"), and discusses how pandas approaches the problem, with many examples throughout. Users brand-new to pandas should start with...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/index.rst
main
pandas
[ -0.026804547756910324, 0.024976124987006187, -0.014432422816753387, -0.0037179600913077593, 0.08214961737394333, -0.05081053823232651, -0.015084309503436089, 0.02990030311048031, -0.0527949221432209, -0.044096119701862335, 0.05071869492530823, 0.04017151519656181, -0.02049422822892666, -0....
0.009435
.. \_scale: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Scaling to large datasets \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* pandas provides data structures for in-memory analytics, which makes using pandas to analyze datasets that are larger than memory somewhat tricky. Even datasets that are a sizable ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/scale.rst
main
pandas
[ 0.03325990214943886, -0.02132614515721798, -0.05054723471403122, 0.03235363960266113, 0.0400548055768013, -0.07950926572084427, -0.04420175775885582, 0.05412903055548668, -0.02524699829518795, 0.008011083118617535, 0.005409813951700926, 0.009439211338758469, -0.09039855748414993, -0.001791...
-0.012095
a Parquet file and repeating that for each file in a directory. As long as each chunk fits in memory, you can work with datasets that are much larger than memory. .. note:: Chunking works well when the operation you're performing requires zero or minimal coordination between chunks. For more complicated workflows, you'...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/scale.rst
main
pandas
[ -0.04931753873825073, 0.044341232627630234, 0.0039053040090948343, -0.08097599446773529, -0.031777024269104004, -0.06400274485349655, -0.007212428376078606, 0.04125307872891426, -0.015236317180097103, 0.0027956271078437567, 0.01890091598033905, 0.052569251507520676, -0.0431206189095974, -0...
0.006845
.. currentmodule:: pandas .. ipython:: python :suppress: import pandas as pd import numpy as np .. \_boolean: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Nullable Boolean data type \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* .. \_boolean.indexing: Indexing with NA values ----------------------- pandas...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/boolean.rst
main
pandas
[ -0.0038877639453858137, 0.020048676058650017, -0.04282879829406738, -0.00632842443883419, 0.0749184638261795, -0.05384727567434311, 0.05038539692759514, -0.13001666963100433, -0.004983644932508469, 0.02286933921277523, 0.04924439266324043, -0.08795355260372162, -0.02006329968571663, -0.028...
0.014374
.. \_reshaping: {{ header }} \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Reshaping and pivot tables \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* .. \_reshaping.reshaping: pandas provides methods for manipulating a :class:`Series` and :class:`DataFrame` to alter the representation of the data for furthe...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/reshaping.rst
main
pandas
[ -0.06029342859983444, -0.0534810945391655, -0.0505441315472126, -0.04078923165798187, -0.0005576504045166075, -0.04411141201853752, -0.0721435472369194, -0.014060508459806442, -0.02568344585597515, 0.048164140433073044, 0.013211175799369812, 0.0001332706306129694, -0.01173435989767313, -0....
-0.080289
you can use :class:`Grouper` for ``index`` and ``columns`` keywords. For detail of :class:`Grouper`, see :ref:`Grouping with a Grouper specification `. .. ipython:: python pd.pivot\_table(df, values="D", index=pd.Grouper(freq="ME", key="F"), columns="C") .. \_reshaping.pivot.margins: Adding margins ^^^^^^^^^^^^^^ Passi...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/reshaping.rst
main
pandas
[ -0.004489102866500616, -0.03737538307905197, -0.04456833377480507, 0.008098004385828972, -0.014664246700704098, 0.05356371030211449, -0.03726207837462425, -0.017366424202919006, -0.032748330384492874, 0.048603836447000504, 0.050852809101343155, 0.0038521005772054195, -0.0008091803756542504, ...
-0.118702
will be replaced with the default fill value for that data type. .. ipython:: python columns = pd.MultiIndex.from\_tuples( [ ("A", "cat"), ("B", "dog"), ("B", "cat"), ("A", "dog"), ], names=["exp", "animal"], ) index = pd.MultiIndex.from\_product( [("bar", "baz", "foo", "qux"), ("one", "two")], names=["first", "second"...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/reshaping.rst
main
pandas
[ -0.015538910403847694, -0.05149941146373749, 0.010470274835824966, -0.006173023954033852, -0.0011081668781116605, -0.0072739338502287865, 0.07416202127933502, -0.05987366661429405, 0.012791604734957218, -0.0009634859161451459, 0.06125742569565773, -0.03247033432126045, -0.03360075503587723, ...
-0.022615
= pd.get\_dummies(df, prefix=["from\_A", "from\_B"]) from\_list from\_dict = pd.get\_dummies(df, prefix={"B": "from\_B", "A": "from\_A"}) from\_dict To avoid collinearity when feeding the result to statistical models, specify ``drop\_first=True``. .. ipython:: python s = pd.Series(list("abcaa")) pd.get\_dummies(s) pd.g...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/reshaping.rst
main
pandas
[ -0.056365106254816055, -0.03137262910604477, 0.04335850477218628, 0.00882255844771862, -0.005463003646582365, -0.004554656334221363, 0.045366525650024414, -0.05740286782383919, 0.035714976489543915, 0.012052572332322598, 0.07870344817638397, -0.03408763185143471, -0.04577447474002838, -0.0...
-0.093996
within each group defined by the first two :class:`Series`: .. ipython:: python pd.crosstab(df["A"], df["B"], values=df["C"], aggfunc="sum") Adding margins ~~~~~~~~~~~~~~ ``margins=True`` will add a row and column with an ``All`` label with partial group aggregates across the categories on the rows and columns: .. ipyt...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/reshaping.rst
main
pandas
[ -0.006187598221004009, -0.017105408012866974, -0.06013777479529381, -0.0046959538012743, 0.007086524739861488, 0.032450366765260696, -0.028391050174832344, -0.07731103152036667, -0.036767374724149704, 0.012071298435330391, 0.008342496119439602, -0.0796678438782692, -0.1169445812702179, -0....
0.000396
.. \_udf: {{ header }} \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* User-Defined Functions (UDFs) \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* In pandas, User-Defined Functions (UDFs) provide a way to extend the library’s functionality by allowing users to apply custom computations to their ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/user_defined_functions.rst
main
pandas
[ -0.06353773921728134, -0.081650011241436, -0.031194154173135757, -0.029570186510682106, 0.01990128867328167, -0.08755283802747726, -0.021151093766093254, 0.0010133427567780018, 0.009118318557739258, 0.04987473785877228, 0.016953647136688232, -0.017749842256307602, -0.07276075333356857, 0.0...
0.114654
and is designed for different use cases. Understanding the purpose and behavior of each method will help you make informed decisions, ensuring more efficient and maintainable code. .. note:: Some of these methods can also be applied to groupby, resample, and various window objects. See :ref:`groupby`, :ref:`resample()`...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/user_defined_functions.rst
main
pandas
[ -0.020117590203881264, -0.01915782131254673, -0.0612306073307991, -0.011508298106491566, 0.08013883233070374, -0.09334909915924072, -0.0563264936208725, 0.02348282001912594, -0.027079522609710693, 0.03625292330980301, 0.04881684482097626, -0.022178513929247856, -0.025509817525744438, -0.05...
0.131942
``pipe`` method is similar to ``map`` and ``apply``, but the function receives the whole ``Series`` or ``DataFrame`` it is called on. .. ipython:: python temperature = pd.DataFrame({ "NYC": [14, 21, 23], "Los Angeles": [22, 28, 31], }) def normalize(df): return df / df.mean().mean() temperature.pipe(normalize) This is ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/user_defined_functions.rst
main
pandas
[ 0.0467853881418705, -0.015022926032543182, 0.023895064368844032, 0.004494645167142153, -0.02684742957353592, -0.09613490849733353, -0.04485376551747322, 0.03315955027937889, -0.036305882036685944, -0.0008434327319264412, 0.026879161596298218, 0.006674232427030802, -0.04983201250433922, 0.0...
0.086402
5.6435 secs Vectorized: 0.0043 secs Vectorized operations in pandas are significantly faster than using :meth:`DataFrame.apply` with UDFs because they leverage highly optimized C functions via ``NumPy`` to process entire arrays at once. This approach avoids the overhead of looping through rows in Python and making sepa...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/user_defined_functions.rst
main
pandas
[ -0.020448217168450356, -0.060897305607795715, -0.03390787914395332, -0.019269578158855438, 0.056288864463567734, -0.17762471735477448, -0.07235367596149445, 0.005525065120309591, -0.026884375140070915, 0.03585362434387207, -0.03365650773048401, 0.023563535884022713, -0.08626285940408707, -...
0.044535
.. \_io: .. currentmodule:: pandas =============================== IO tools (text, CSV, HDF5, ...) =============================== The pandas I/O API is a set of top level ``reader`` functions accessed like :func:`pandas.read\_csv` that generally return a pandas object. The corresponding ``writer`` functions are object...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.04403560608625412, -0.017171217128634453, -0.08755877614021301, 0.08910945057868958, 0.04141391068696976, -0.13506555557250977, 0.022129913792014122, 0.046665605157613754, 0.04592479020357132, 0.04116169363260269, -0.008359591476619244, -0.014859418384730816, -0.026929721236228943, -0.0...
0.112777
or False, optional, default ``None`` Column(s) to use as the row labels of the ``DataFrame``, either given as string name or column index. If a sequence of int / str is given, a MultiIndex is used. .. note:: ``index\_col=False`` can be used to force pandas to \*not\* use the first column as the index, e.g. when you hav...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.012832367792725563, 0.0009341102559119463, -0.06098533794283867, -0.011752907186746597, 0.07327930629253387, -0.06600821763277054, 0.008847573772072792, -0.027834517881274223, 0.043224141001701355, 0.02323063649237156, 0.06938078254461288, 0.04569707810878754, -0.05242284759879112, -0.0...
0.018834
supported by the pyarrow engine. Some features of the "pyarrow" engine are unsupported or may not work correctly. converters : dict, default ``None`` Dict of functions for converting values in certain columns. Keys can either be integers or column labels. true\_values : list, default ``None`` Values to consider as ``Tr...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.027633465826511383, 0.03614453226327896, -0.08330228179693222, -0.02346443571150303, -0.03605232387781143, -0.052344512194395065, 0.007252772804349661, -0.011257415637373924, -0.02839759923517704, 0.012746889144182205, 0.030593231320381165, 0.06316805630922318, -0.00813913345336914, -0....
-0.082832
A fast-path exists for iso8601-formatted dates. date\_format : str or dict of column -> format, default ``None`` If used in conjunction with ``parse\_dates``, will parse dates according to this format. For anything more complex, please read in as ``object`` and then apply :func:`to\_datetime` as-needed. .. versionadded...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.009382922202348709, 0.0025271561462432146, -0.01999789848923683, 0.046062979847192764, -0.042728278785943985, -0.0712379738688469, -0.06635905057191849, 0.027810540050268173, -0.03779461234807968, -0.018038669601082802, 0.044067542999982834, -0.0582943856716156, -0.09534884989261627, -0....
0.019265
``quoting``. If it is necessary to override values, a ParserWarning will be issued. See :class:`python:csv.Dialect` documentation for more details. Error handling ++++++++++++++ on\_bad\_lines : {{'error', 'warn', 'skip'}}, default 'error' Specifies what to do upon encountering a bad line (a line with too many fields)....
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.04797383025288582, 0.050078656524419785, 0.010285384953022003, 0.031159458681941032, 0.004969440400600433, -0.05461731553077698, -0.0073179458267986774, -0.00612255884334445, -0.03650757670402527, 0.027073105797171593, -0.04645964503288269, -0.061764393001794815, 0.016003398224711418, -...
0.043736
order, create a :class:`~pandas.api.types.CategoricalDtype` ahead of time, and pass that for that column's ``dtype``. .. ipython:: python from pandas.api.types import CategoricalDtype dtype = CategoricalDtype(["d", "c", "b", "a"], ordered=True) pd.read\_csv(StringIO(data), dtype={"col1": dtype}).dtypes When using ``dty...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.010776967741549015, -0.004767327569425106, 0.022596338763833046, 0.008258981630206108, -0.028801295906305313, -0.03865089267492294, -0.05237823724746704, -0.001938347239047289, 0.02511569671332836, -0.016001518815755844, 0.02742820233106613, 0.004096049349755049, -0.05944990739226341, -0...
0.022537
numbers; the parameter ``header`` uses row numbers (ignoring commented/empty lines), while ``skiprows`` uses line numbers (including commented/empty lines): .. ipython:: python data = "#comment\na,b,c\nA,B,C\n1,2,3" pd.read\_csv(StringIO(data), comment="#", header=1) data = "A,B,C\n#comment\na,b,c\n1,2,3" pd.read\_csv(...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.05790034681558609, 0.05553634464740753, -0.001230756752192974, 0.01583421230316162, -0.0195222906768322, -0.026157015934586525, 0.026018142700195312, 0.02087097242474556, 0.017944758757948875, 0.006561423186212778, 0.043853167444467545, -0.012415294535458088, 0.06066397577524185, -0.077...
0.054434
significantly faster, ~20x has been observed. Date parsing functions ++++++++++++++++++++++ Finally, the parser allows you to specify a custom ``date\_format``. Performance-wise, you should try these methods of parsing dates in order: 1. If you know the format, use ``date\_format``, e.g.: ``date\_format="%d/%m/%Y"`` or...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.03120499849319458, 0.021658003330230713, -0.0024500826839357615, 0.03442397713661194, 0.034662000834941864, -0.051622696220874786, -0.05503147095441818, 0.0059965504333376884, -0.011855266988277435, 0.022544007748365402, -0.013194363564252853, -0.0779869556427002, -0.06102742627263069, -...
-0.059119
round-trip converter (which is guaranteed to round-trip values after writing to a file). For example: .. ipython:: python val = "0.3066101993807095471566981359501369297504425048828125" data = "a,b,c\n1,2,{0}".format(val) abs( pd.read\_csv( StringIO(data), engine="c", float\_precision=None, )["c"][0] - float(val) ) .. \...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.012111447751522064, 0.09043271839618683, -0.053426533937454224, 0.004825317766517401, -0.06676053255796432, -0.05958159267902374, 0.0008028773590922356, 0.0661943331360817, -0.0014169529313221574, -0.03224986046552658, 0.013198712840676308, -0.051837820559740067, -0.016007423400878906, ...
0.073783
errors will be silently skipped. .. ipython:: python bad\_lines\_func = lambda line: print(line) data = 'name,type\nname a,a is of type a\nname b,"b\" is of type b"' data pd.read\_csv(StringIO(data), on\_bad\_lines=bad\_lines\_func, engine="python") The line was not processed in this case, as a "bad line" here is cause...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.018341543152928352, 0.07872571796178818, 0.0258011557161808, 0.04937991872429848, -0.032294780015945435, -0.0625394657254219, 0.055271733552217484, 0.018947534263134003, -0.05127745866775513, -0.0037555755116045475, -0.001718792598694563, -0.05658351629972458, 0.013926426880061626, -0.0...
-0.029515
"id8141 360.242940 149.910199 11950.7\n" "id1594 444.953632 166.985655 11788.4\n" "id1849 364.136849 183.628767 11806.2\n" "id1230 413.836124 184.375703 11916.8\n" "id1948 502.953953 173.237159 12468.3" ) with open("bar.csv", "w") as f: f.write(data1) In order to parse this file into a ``DataFrame``, we simply need to ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.02299877069890499, 0.02785564586520195, -0.02719973772764206, 0.0033584763295948505, 0.05738741531968117, -0.08309468626976013, -0.014253363944590092, 0.09697221219539642, -0.0272615198045969, 0.014994677156209946, -0.03743961453437805, 0.007538571488112211, -0.06195567175745964, -0.070...
-0.041284
.. note:: If an ``index\_col`` is not specified (e.g. you don't have an index, or wrote it with ``df.to\_csv(..., index=False)``), then any ``names`` on the columns index will be \*lost\*. .. ipython:: python :suppress: os.remove("mi.csv") os.remove("mi2.csv") .. \_io.sniff: Automatically "sniffing" the delimiter '''''...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.017318692058324814, -0.009892518632113934, 0.005172673612833023, 0.05813315883278847, 0.12419591099023819, -0.1319219321012497, 0.04592717066407204, -0.0690838098526001, 0.07599534094333649, 0.009693031199276447, 0.03195706009864807, 0.03562936931848526, -0.031690143048763275, -0.049802...
-0.06342
`s3fs `\_ library: .. code-block:: python df = pd.read\_json("s3://pandas-test/adatafile.json") When dealing with remote storage systems, you might need extra configuration with environment variables or config files in special locations. For example, to access data in your S3 bucket, you will need to define credentials...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.011938470415771008, -0.07183411717414856, -0.1434759795665741, 0.008014782331883907, 0.049266617745161057, -0.06690797209739685, -0.02908935397863388, 0.051142483949661255, 0.01392344944179058, 0.04016345739364624, -0.006005960516631603, -0.033102698624134064, 0.004952782299369574, -0.0...
-0.028247
objects Writing a formatted string ++++++++++++++++++++++++++ .. \_io.formatting: The ``DataFrame`` object has an instance method ``to\_string`` which allows control over the string representation of the object. All arguments are optional: \* ``buf`` default None, for example a StringIO object \* ``columns`` default No...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.008934028446674347, -0.01203880738466978, -0.09053672850131989, 0.05562026798725128, -0.01849859207868576, -0.0795646533370018, 0.06556613743305206, -0.010337558574974537, 0.02539617381989956, 0.035843625664711, 0.05014824867248535, -0.07365792989730835, -0.008756388910114765, 0.0076256...
0.159763
string. Consider the following ``DataFrame`` and ``Series``: .. ipython:: python dfjo = pd.DataFrame( dict(A=range(1, 4), B=range(4, 7), C=range(7, 10)), columns=list("ABC"), index=list("xyz"), ) dfjo sjo = pd.Series(dict(x=15, y=16, z=17), name="D") sjo \*\*Column oriented\*\* (the default for ``DataFrame``) serialize...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.03007097914814949, 0.019850129261612892, -0.0002533146762289107, -0.0026757221203297377, 0.0151792261749506, -0.025440525263547897, -0.047790925949811935, -0.02306932583451271, 0.00925571657717228, -0.03525970131158829, 0.035654522478580475, 0.05348728224635124, -0.09581375867128372, 0....
0.022532
file. For file URLs, a host is expected. For instance, a local file could be file ://localhost/path/to/table.json \* ``typ`` : type of object to recover (series or frame), default 'frame' \* ``orient`` : Series : \* default is ``index`` \* allowed values are {``split``, ``records``, ``index``} DataFrame \* default is `...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.012641268782317638, 0.04996457323431969, -0.048803530633449554, 0.00840941071510315, 0.006570769473910332, -0.06597764045000076, -0.05565202236175537, 0.045666828751564026, 0.04462157189846039, 0.08069971948862076, 0.020701341331005096, 0.038571737706661224, -0.03873371705412865, 0.0278...
-0.029822
as before serialization \* a column that was ``float`` data will be converted to ``integer`` if it can be done safely, e.g. a column of ``1.`` \* bool columns will be converted to ``integer`` on reconstruction Thus there are times where you may want to specify specific dtypes via the ``dtype`` keyword argument. Reading...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.027895234525203705, 0.015614364296197891, -0.04505040869116783, 0.007818753831088543, -0.037575799971818924, -0.07520986348390579, -0.02291734702885151, 0.047866057604551315, -0.05039031058549881, -0.04178345948457718, 0.01843300648033619, -0.024063238874077797, -0.05946797877550125, 0....
0.110295
JSON includes information on the field names, types, and other attributes. You can use the orient ``table`` to build a JSON string with two fields, ``schema`` and ``data``. .. ipython:: python df = pd.DataFrame( { "A": [1, 2, 3], "B": ["a", "b", "c"], "C": pd.date\_range("2016-01-01", freq="D", periods=3), }, index=pd....
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.009163116104900837, 0.04019667208194733, 0.03503983095288277, -0.0034650349989533424, -0.013904491439461708, 0.03139473497867584, -0.030476730316877365, 0.011652580462396145, 0.01574683003127575, -0.008114111609756947, 0.050909411162137985, 0.03859441727399826, -0.08218178898096085, -0.0...
0.074418
names beginning with ``'level\_'`` within a :class:`MultiIndex`. These are used by default in :func:`DataFrame.to\_json` to indicate missing values and the subsequent read cannot distinguish the intent. .. ipython:: python :okwarning: df.index.name = "index" df.to\_json("test.json", orient="table") new\_df = pd.read\_j...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.006968894507735968, -0.002696843584999442, -0.05261571705341339, 0.049116458743810654, 0.030348777770996094, -0.06369868665933609, 0.007678057532757521, 0.021865416318178177, -0.021294767037034035, -0.015440233051776886, 0.1038689911365509, 0.03475828468799591, -0.07494978606700897, 0.0...
0.076363
a table that contains specific text: .. code-block:: python match = "Metcalf Bank" df\_list = pd.read\_html(url, match=match) Specify a header row (by default `` `` or `` `` elements located within a ```` are used to form the column index, if multiple rows are contained within ```` then a MultiIndex is created); if spe...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.03819623589515686, -0.006153058726340532, -0.062302906066179276, 0.002697297604754567, 0.062409039586782455, -0.06339067220687866, -0.007410864345729351, -0.04275498911738396, -0.02205081470310688, 0.04383036121726036, 0.06282932311296463, 0.008258234709501266, 0.008682616986334324, -0....
0.009523
argument will limit the columns shown: .. ipython:: python html = df.to\_html(columns=[0]) print(html) display(HTML(html)) ``float\_format`` takes a Python callable to control the precision of floating point values: .. ipython:: python html = df.to\_html(float\_format="{0:.10f}".format) print(html) display(HTML(html)) ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.006496921181678772, -0.010700136423110962, -0.09607873111963272, 0.010912998579442501, 0.055670514702796936, -0.049598578363657, 0.026869140565395355, -0.06302553415298462, -0.012776287272572517, 0.013440823182463646, 0.017338398844003677, 0.029619315639138222, -0.018089957535266876, -0....
-0.066345
https://www.crummy.com/software/BeautifulSoup .. |lxml| replace:: \*\*lxml\*\* .. \_lxml: https://lxml.de .. \_io.latex: LaTeX ----- Currently there are no methods to read from LaTeX, only output methods. Writing to LaTeX files '''''''''''''''''''''' .. note:: DataFrame \*and\* Styler objects currently have a ``to\_lat...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.009498560801148415, 0.024685543030500412, 0.04078191518783569, -0.022900493815541267, 0.0963299572467804, -0.02953997254371643, -0.11895233392715454, -0.017793595790863037, -0.021817242726683617, 0.06470763683319092, 0.029118424281477928, 0.037475310266017914, 0.00057931337505579, -0.06...
-0.084678
assign a temporary prefix will return no nodes and raise a ``ValueError``. But assigning \*any\* temporary name to correct URI allows parsing by nodes. .. ipython:: python xml = """xml version='1.0' encoding='utf-8'? square 360 4.0 circle 360 triangle 180 3.0 """ df = pd.read\_xml(StringIO(xml), xpath="//pandas:row", n...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.01301012933254242, -0.014062872156500816, -0.013080179691314697, 0.021673941984772682, 0.020839212462306023, -0.1395241618156433, -0.04403865709900856, -0.002676403382793069, 0.009986943565309048, -0.01793646067380905, 0.11814739555120468, -0.03681683912873268, 0.021921848878264427, -0....
-0.02016
Declaration by United Nations 0 8435 3 Constitution of the United States of America 0 8435 4 Declaration of Independence (Israel) 0 17858 ... ... ... ... 3578760 Page:Black cat 1897 07 v2 n10.pdf/17 104 219649 3578761 Page:Black cat 1897 07 v2 n10.pdf/43 104 219649 3578762 Page:Black cat 1897 07 v2 n10.pdf/44 104 21964...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.025312887504696846, 0.012306633405387402, -0.04151321202516556, -0.040720384567976, 0.005352057050913572, 0.016135353595018387, -0.01450317446142435, -0.07001972943544388, -0.056456416845321655, 0.05429280549287796, 0.07917457818984985, 0.04688218608498573, 0.045252345502376556, -0.0465...
0.072235
but relatively unnoticeable on small to medium size files. .. \_`W3C specifications`: https://www.w3.org/TR/xml/ .. \_`XML schemas`: https://en.wikipedia.org/wiki/List\_of\_types\_of\_XML\_schemas .. \_`etree`: https://docs.python.org/3/library/xml.etree.elementtree.html .. \_io.excel: Excel files ----------- The :func...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.04542645066976547, -0.02367958426475525, -0.12210039049386978, -0.002710893051698804, 0.01900731399655342, -0.011479699052870274, -0.11447955667972565, 0.09530848264694214, 0.04866264760494232, 0.05927445366978645, 0.02787100151181221, 0.01551030669361353, -0.011579177342355251, -0.0556...
0.051811
is ``sheet\_name``, not to be confused with ``ExcelFile.sheet\_names``. .. note:: An ExcelFile's attribute ``sheet\_names`` provides access to a list of sheets. \* The arguments ``sheet\_name`` allows specifying the sheet or sheets to read. \* The default value for ``sheet\_name`` is 0, indicating to read the first she...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.06638263911008835, 0.05879969149827957, -0.07859242707490921, 0.014750822447240353, 0.007107002194970846, -0.023168204352259636, 0.04284433647990227, 0.03451884537935257, 0.05117905139923096, 0.012366031296551228, 0.024737967178225517, 0.016330469399690628, 0.01196622010320425, -0.06065...
0.01673
of strings, it is assumed that each string corresponds to a column name provided either by the user in ``names`` or inferred from the document header row(s). Those strings define which columns will be parsed: .. code-block:: python pd.read\_excel("path\_to\_file.xls", "Sheet1", usecols=["foo", "bar"]) Element order is ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.04466498643159866, 0.06724191457033157, -0.07191643863916397, 0.03595913574099541, -0.0649208277463913, -0.0021916290279477835, -0.03254779800772667, 0.08570479601621628, 0.05029887333512306, -0.01469709724187851, 0.017596540972590446, 0.0058283135294914246, -0.013070950284600258, -0.06...
-0.072055
write to (``.xlsx``) files. \* For the engine odf, pandas is using :func:`odf.opendocument.OpenDocumentSpreadsheet` to write to (``.ods``) files. Writing Excel files to memory +++++++++++++++++++++++++++++ pandas supports writing Excel files to buffer-like objects such as ``StringIO`` or ``BytesIO`` using :class:`~pand...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.02483336254954338, 0.016002634540200233, -0.08340992778539658, 0.014211272820830345, -0.007748333737254143, -0.05613965913653374, -0.06095415726304054, 0.08581326901912689, 0.04279971495270729, 0.02271158993244171, 0.002503220224753022, 0.029185179620981216, -0.004699715878814459, -0.08...
0.000765
can write OpenDocument spreadsheets .. code-block:: python # Writes DataFrame to a .ods file df.to\_excel("path\_to\_file.ods", engine="odf") .. \_io.xlsb: Binary Excel (.xlsb) files -------------------------- The :func:`~pandas.read\_excel` method can also read binary Excel files using the :ref:`calamine` engine. The ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.04203339293599129, -0.004722670651972294, -0.13333405554294586, -0.02302752435207367, 0.01857381872832775, -0.06651816517114639, -0.11217709630727768, 0.08186669647693634, 0.07724329829216003, 0.027041226625442505, -0.011919747106730938, 0.032111357897520065, -0.024358853697776794, -0.0...
-0.024692
and must contain only one data file to be read. The compression type can be an explicit parameter or be inferred from the file extension. If 'infer', then use ``gzip``, ``bz2``, ``zip``, ``xz``, ``zstd`` if filename ends in ``'.gz'``, ``'.bz2'``, ``'.zip'``, ``'.xz'``, or ``'.zst'``, respectively. The compression param...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.07651344686746597, 0.09007951617240906, -0.07389377802610397, 0.01883338764309883, 0.0057790325954556465, -0.05650939792394638, 0.02677975408732891, 0.041557490825653076, -0.03632492944598198, 0.022653141990303993, -0.014910053461790085, 0.056841183453798294, 0.01695161871612072, 0.0456...
0.013406
python :suppress: :okexcept: os.remove("store\_tl.h5") HDFStore will by default not drop rows that are all missing. To drop all-NaN rows before writing, use :meth:`DataFrame.dropna` before calling :meth:`~DataFrame.to\_hdf`. .. deprecated:: 3.1.0 The ``dropna`` keyword in :meth:`~DataFrame.to\_hdf`, :meth:`HDFStore.put...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.006112975999712944, -0.0314105860888958, -0.011011534370481968, -0.010008896701037884, 0.0804467722773552, -0.09840064495801926, -0.055905137211084366, -0.01299787126481533, -0.013335428200662136, 0.04317164048552513, 0.0792861357331276, -0.00615898659452796, -0.003302442841231823, -0.08...
-0.088871
using the root node store.root.foo.bar.bah Instead, use explicit string based keys: .. ipython:: python store["foo/bar/bah"] .. \_io.hdf5-types: Storing types ''''''''''''' Storing mixed types in a table ++++++++++++++++++++++++++++++ Storing mixed-dtype data is supported. Strings are stored as a fixed-width using the ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.025423821061849594, -0.00950478482991457, -0.049794360995292664, 0.03469109907746315, -0.03605734556913376, -0.06380315124988556, -0.027856793254613876, 0.057974617928266525, -0.06827636063098907, 0.06087348237633705, 0.046258777379989624, 0.0033599096350371838, -0.0010642275447025895, -...
-0.04543
space, e.g. ``date`` .. note:: Passing a string to a query by interpolating it into the query expression is not recommended. Simply assign the string of interest to a variable and use that variable in an expression. For example, do this .. code-block:: python string = "HolyMoly'" store.select("df", "index == string") i...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.03896252065896988, 0.05359162762761116, 0.0039062402211129665, 0.04748702049255371, -0.06464704871177673, -0.009813687764108181, 0.05287428945302963, 0.09601716697216034, -0.054352056235075, 0.044801075011491776, 0.015103265643119812, -0.04080053046345711, -0.0026158629916608334, -0.045...
-0.045432
passing new parameters store.create\_table\_index("df", optlevel=9, kind="full") i = store.root.df.table.cols.index.index i.optlevel, i.kind Oftentimes when appending large amounts of data to a store, it is useful to turn off index creation for each append, then recreate at the end. .. ipython:: python df\_1 = pd.DataF...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.025491341948509216, -0.047935500741004944, -0.052948422729969025, 0.03372007608413696, 0.025464190170168877, -0.07227743417024612, -0.0007688890327699482, -0.017450401559472084, -0.026569141075015068, 0.08984966576099396, 0.0748736634850502, 0.04040878266096115, -0.022908080369234085, -0...
-0.088228
(a.k.a the index locations) of your query. This returns an ``Index`` of the resulting locations. These coordinates can also be passed to subsequent ``where`` operations. .. ipython:: python df\_coord = pd.DataFrame( np.random.randn(1000, 2), index=pd.date\_range("20000101", periods=1000) ) store.append("df\_coord", df\...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.054533202201128006, -0.03819849342107773, 0.027601059526205063, 0.045459721237421036, 0.06457051634788513, -0.012154337018728256, 0.02875225991010666, -0.0527949258685112, 0.00012340072134975344, 0.04324185475707054, 0.03599454462528229, 0.015214549377560616, -0.07324396073818207, -0.092...
0.002047
and ids in the ``minor\_axis``. The data is then interleaved like this: \* date\_1 \* id\_1 \* id\_2 \* . \* id\_n \* date\_2 \* id\_1 \* . \* id\_n It should be clear that a delete operation on the ``major\_axis`` will be fairly quick, as one chunk is removed, then the following data moved. On the other hand a delete ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.041701190173625946, -0.008269139565527439, -0.003562356811016798, -0.014616331085562706, 0.09547494351863861, -0.011247924529016018, -0.004486491903662682, -0.06240531802177429, -0.02755933627486229, 0.090399369597435, 0.0752914696931839, 0.04487432911992073, -0.009838324040174484, -0.0...
-0.039001
you may want to use :py:func:`~os.fsync` before releasing write locks. For convenience you can use ``store.flush(fsync=True)`` to do this for you. \* Once a ``table`` is created columns (DataFrame) are fixed; only exactly the same columns can be appended \* Be aware that timezones (e.g., ``zoneinfo.ZoneInfo('US/Eastern...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.023100582882761955, -0.020412465557456017, -0.09302283823490143, 0.022689566016197205, 0.04943133890628815, -0.05058573931455612, -0.03726697713136673, 0.0012540946481749415, -0.007272787392139435, 0.054004330188035965, 0.01838647946715355, 0.008081355132162571, -0.0349305085837841, -0.0...
-0.085033
will be the maximum of the length of any string passed .. ipython:: python dfs = pd.DataFrame({"A": "foo", "B": "bar"}, index=list(range(5))) dfs # A and B have a size of 30 store.append("dfs", dfs, min\_itemsize=30) store.get\_storer("dfs").table # A is created as a data\_column with a size of 30 # B is size is calcul...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.02916288934648037, -0.053350355476140976, -0.08247296512126923, -0.02700996585190296, 0.025350552052259445, -0.08082757145166397, -0.019850265234708786, 0.05621538311243057, -0.06387507170438766, 0.05860969424247742, 0.07012845575809479, 0.006679754238575697, -0.03576969727873802, -0.037...
-0.059664
as possible while still maintaining good read performance. Parquet is designed to faithfully serialize and de-serialize ``DataFrame`` s, supporting all of the pandas dtypes, including extension dtypes such as datetime with timezone. Several caveats. \* Duplicate column names and non-string columns names are not support...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.037048131227493286, -0.046347565948963165, -0.037857986986637115, -0.062339335680007935, -0.040860794484615326, -0.07436078786849976, -0.0028160845395177603, 0.004220894537866116, -0.021393366158008575, -0.038787052035331726, 0.0006503199110738933, 0.04191477969288826, -0.1058151796460151...
-0.014102
indexes when writing, pass ``index=False`` to :func:`~pandas.DataFrame.to\_parquet`: .. ipython:: python df.to\_parquet("test.parquet", index=False) This creates a parquet file with just the two expected columns, ``a`` and ``b``. If your ``DataFrame`` has a custom index, you won't get it back when you load this file in...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.014337598346173763, -0.031191933900117874, -0.027656178921461105, -0.0024775301571935415, -0.002609030343592167, -0.09279846400022507, 0.03230544179677963, -0.033293601125478745, 0.032659854739904404, 0.01804286614060402, 0.0016458056634292006, 0.07808247953653336, -0.09840628504753113, ...
-0.091187
catalog, it works in the same way as for :func:`read\_iceberg` with the ``catalog\_name`` and ``catalog\_properties`` parameters. The location of the table can be specified with the ``location`` parameter: .. code-block:: python df.to\_iceberg( "my\_table", catalog\_name="my\_catalog", location="s://my-data-lake/my-ice...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.052823182195425034, -0.050091519951820374, -0.09528172016143799, 0.004670017398893833, 0.03019651770591736, -0.05566098541021347, 0.02032569795846939, 0.041689325124025345, -0.048124901950359344, 0.00858689658343792, 0.06642568856477737, 0.005252214148640633, -0.004086494445800781, -0.0...
0.021691
ADBC driver to connect to your database. .. code-block:: python import adbc\_driver\_sqlite.dbapi as sqlite\_dbapi # Create the connection with sqlite\_dbapi.connect("sqlite:///:memory:") as conn: df = pd.read\_sql\_table("data", conn) To connect with SQLAlchemy you use the :func:`create\_engine` function to create an ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.02733338437974453, -0.056383274495601654, -0.1536833941936493, 0.04942420497536659, -0.11641835421323776, -0.08379191160202026, 0.06449954956769943, 0.023425843566656113, -0.06389934569597244, -0.029359059408307076, -0.03837337717413902, -0.020759113132953644, 0.008976588025689125, -0.0...
-0.011968
| | | | | [#f1]\_ | | +-----------------+-----------------------+----------------+---------+ .. rubric:: Footnotes .. [#f1] Not implemented as of writing, but theoretically possible If you are interested in preserving database types as best as possible throughout the lifecycle of your DataFrame, users are encouraged to...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.051006004214286804, -0.06953949481248856, -0.09695914387702942, 0.02648141235113144, 0.0062646460719406605, -0.06712102144956589, 0.03693714737892151, -0.006234315689653158, -0.09999760240316391, -0.021375607699155807, 0.010475770570337772, 0.08066502958536148, -0.039387255907058716, -0...
-0.060472
the SQLAlchemy `documentation `\_\_. - callable with signature ``(pd\_table, conn, keys, data\_iter)``: This can be used to implement a more performant insertion method based on specific backend dialect features. Example of a callable using PostgreSQL `COPY clause `\_\_:: # Alternative to\_sql() \*method\* for DBs that...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.05402475222945213, -0.03478680178523064, -0.11774171143770218, 0.029505738988518715, -0.10064031183719635, -0.07368004322052002, 0.0548475906252861, 0.03916268050670624, -0.04451300948858261, -0.013613044284284115, 0.013839513063430786, 0.01080260518938303, 0.05655790865421295, -0.09452...
0.003198
\* FROM data\_chunks", engine, chunksize=5): print(chunk) Engine connection examples '''''''''''''''''''''''''' To connect with SQLAlchemy you use the :func:`create\_engine` function to create an engine object from database URI. You only need to create the engine once per database you are connecting to. .. code-block::...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.03465684503316879, -0.049330782145261765, -0.07504966109991074, 0.009212737902998924, -0.12693476676940918, -0.06307844072580338, 0.03535688295960426, 0.035365283489227295, -0.08877092599868774, -0.037893131375312805, -0.05674973130226135, -0.04180304706096649, 0.04147619381546974, -0.1...
-0.069075
characters, a limitation imposed by the version 115 dta file format. Attempting to write \*Stata\* dta files with strings longer than 244 characters raises a ``ValueError``. .. \_io.stata\_reader: Reading from Stata format ''''''''''''''''''''''''' The top-level function ``read\_stata`` will read a dta file and return ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.10491406172513962, -0.03020600788295269, -0.0984080359339714, -0.012241419404745102, -0.051116738468408585, -0.07424546033143997, -0.017263280227780342, 0.10308893024921417, 0.008955930359661579, 0.062137965112924576, 0.0629582554101944, 0.05599179491400719, -0.08386276662349701, -0.000...
0.068689
there is a simple mapping between the original \*Stata\* data values and the category codes of imported Categorical variables: missing values are assigned code ``-1``, and the smallest original value is assigned ``0``, the second smallest is assigned ``1`` and so on until the largest original value is assigned the code...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.052572861313819885, -0.05262375250458717, -0.17277289927005768, 0.03781716525554657, -0.03675070032477379, 0.02961709164083004, 0.032203953713178635, 0.03407991677522659, -0.017201922833919525, 0.022540757432579994, 0.033853836357593536, -0.00020741844491567463, 0.026895133778452873, -0...
0.041969
int64 dtypes: float64(1), int64(1) memory usage: 15.3 MB The following test functions will be used below to compare the performance of several IO methods: .. code-block:: python import numpy as np import os sz = 1000000 df = pd.DataFrame({"A": np.random.randn(sz), "B": [1] \* sz}) sz = 1000000 np.random.seed(42) df = p...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ 0.02983228676021099, -0.05839647725224495, -0.11645223945379257, 0.04608948901295662, 0.040153395384550095, -0.17541268467903137, 0.058674514293670654, 0.004969778936356306, -0.02615879662334919, 0.07554132491350174, -0.01823076419532299, 0.01964876987040043, -0.04653019458055496, -0.05977...
0.071334
test\_pickle\_read() 18.4 ms ± 191 µs per loop (mean ± std. dev. of 7 runs, 100 loops each) In [22]: %timeit test\_pickle\_read\_compress() 915 ms ± 7.48 ms per loop (mean ± std. dev. of 7 runs, 1 loop each) In [23]: %timeit test\_parquet\_read() 24.4 ms ± 146 µs per loop (mean ± std. dev. of 7 runs, 10 loops each) The...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/io.rst
main
pandas
[ -0.07633555680513382, 0.014693964272737503, -0.053407106548547745, 0.009028095752000809, 0.0009882680606096983, -0.1720193773508072, -0.0049546388909220695, 0.044697105884552, 0.07391320914030075, 0.03749817609786987, -0.02407860942184925, -0.0011341202771291137, -0.0623820424079895, -0.07...
-0.004705
.. currentmodule:: pandas {{ header }} .. \_integer\_na: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Nullable integer data type \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* :class:`arrays.IntegerArray` uses :attr:`pandas.NA` as its missing value. In :ref:`missing\_data`, we saw that pandas primarily us...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/integer_na.rst
main
pandas
[ -0.02520606853067875, 0.0294378399848938, -0.10255367308855057, 0.028185585513710976, 0.0826655775308609, -0.047124508768320084, 0.028741363435983658, -0.04106631502509117, 0.00011317794269416481, -0.02391553670167923, 0.023852361366152763, -0.05015422776341438, -0.01542400661855936, -0.03...
-0.010475
.. \_gotchas: {{ header }} \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Frequently Asked Questions (FAQ) \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* .. \_df-memory-usage: DataFrame memory usage ---------------------- The memory usage of a :class:`DataFrame` (including the index)...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/gotchas.rst
main
pandas
[ 0.003930437844246626, 0.043903056532144547, -0.12938286364078522, 0.05829010531306267, 0.07146477699279785, -0.07465154677629471, 0.08316529542207718, 0.03809382766485214, 0.04721760377287865, -0.008743020705878735, 0.036307815462350845, -0.025332177057862282, -0.017826955765485764, -0.013...
0.055788
the \*\*index\*\*, not membership among the values. .. ipython:: python s = pd.Series(range(5), index=list("abcde")) 2 in s 'b' in s If this behavior is surprising, keep in mind that using ``in`` on a Python dictionary tests keys, not values, and :class:`Series` are dict-like. To test for membership in the values, use ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/gotchas.rst
main
pandas
[ -0.021378271281719208, -0.042259618639945984, -0.013804967515170574, -0.003916746936738491, 0.07092220336198807, -0.05866518244147301, 0.024006379768252373, -0.018165744841098785, 0.0008771013817749918, -0.002355897566303611, 0.026439988985657692, 0.015980185940861702, 0.0021417990792542696,...
-0.048217
In the absence of high performance ``NA`` support being built into NumPy from the ground up, the primary casualty is the ability to represent NAs in integer arrays. For example: .. ipython:: python s = pd.Series([1, 2, 3, 4, 5], index=list("abcde")) s s.dtype s2 = s.reindex(["a", "b", "c", "f", "u"]) s2 s2.dtype This t...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/gotchas.rst
main
pandas
[ -0.03005828708410263, -0.06274733692407608, 0.00914789829403162, -0.02083483524620533, 0.006666172295808792, -0.030154194682836533, -0.02606428973376751, -0.07268215715885162, -0.012975145131349564, -0.01890696957707405, -0.01337304525077343, -0.0012063911417499185, 0.008935809135437012, 0...
0.025911
with a different byte order than the one on which you are running Python. A common symptom of this issue is an error like:: Traceback ... ValueError: Big-endian buffer not supported on little-endian compiler To deal with this issue you should convert the underlying NumPy array to the native system byte order \*before\*...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/gotchas.rst
main
pandas
[ 0.07509741932153702, -0.02874918095767498, 0.014124743640422821, -0.055975187569856644, -0.016824038699269295, -0.09961855411529541, -0.0812266394495964, 0.006284364964812994, -0.0336214043200016, 0.04854058846831322, -0.019902952015399933, -0.004441132768988609, -0.08957623690366745, 0.00...
-0.007585
.. \_options: {{ header }} \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Options and settings \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Overview -------- pandas has an options API to configure and customize global behavior related to :class:`DataFrame` display, data behavior and more. Options have a full "dotted-style", case...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/options.rst
main
pandas
[ -0.01973811909556389, 0.03001433052122593, -0.03897038847208023, 0.01877516508102417, -0.00024981366004794836, -0.016579139977693558, 0.008977359160780907, 0.04486709088087082, -0.08292245864868164, -0.00835458468645811, 0.0033761581871658564, -0.006217564456164837, -0.020307451486587524, ...
-0.028734
repr. .. ipython:: python pd.set\_option("display.max\_rows", 8) pd.set\_option("display.min\_rows", 4) # below max\_rows -> all rows shown df = pd.DataFrame(np.random.randn(7, 2)) df # above max\_rows -> only min\_rows (4) rows shown df = pd.DataFrame(np.random.randn(9, 2)) df pd.reset\_option("display.max\_rows") pd....
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/options.rst
main
pandas
[ -0.00454302504658699, -0.013320999220013618, -0.032498035579919815, -0.05015521124005318, 0.04706081375479698, 0.004726273473352194, -0.02541939541697502, -0.00902901217341423, -0.057664696127176285, 0.020061014220118523, 0.02166539616882801, 0.034661464393138885, -0.03379179909825325, 0.0...
-0.101614
By default, an "ambiguous" character's width, such as "¡" (inverted exclamation) in the example below, is taken to be 1. .. ipython:: python df = pd.DataFrame({"a": ["xxx", "¡¡"], "b": ["yyy", "¡¡"]}) df Enabling ``display.unicode.ambiguous\_as\_wide`` makes pandas interpret these characters' widths to be 2. (Note that...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/options.rst
main
pandas
[ 0.03265143930912018, -0.0455845445394516, 0.003866327926516533, 0.004980036057531834, -0.016574030742049217, -0.06905774772167206, -0.017748858779668808, 0.02221551723778248, 0.015269323252141476, -0.03821389004588127, 0.09328395128250122, -0.005513635464012623, -0.06673295050859451, 0.038...
-0.091376
.. \_missing\_data: {{ header }} \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Working with missing data \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Values considered "missing" ~~~~~~~~~~~~~~~~~~~~~~~~~~~ pandas uses different sentinel values to represent a missing (also referred to as NA) depending on the ...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/missing_data.rst
main
pandas
[ -0.031755827367305756, -0.005962993483990431, 0.002071936149150133, 0.03541143611073494, 0.056419871747493744, -0.07109569758176804, -0.021220514550805092, -0.03172339126467705, -0.005718667525798082, 0.0037144734524190426, 0.04143012687563896, -0.09305424243211746, -0.013030936010181904, ...
0.054087
values. See the :ref:`calculation section ` for more. Logical operations ------------------ For logical operations, :class:`NA` follows the rules of the `three-valued logic `\_\_ (or \*Kleene logic\*, similarly to R, SQL and Julia). This logic means to only propagate missing values when it is logically required. For ex...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/missing_data.rst
main
pandas
[ -0.05755576863884926, 0.03813007101416588, 0.0189463309943676, 0.015246298164129257, -0.024717750027775764, -0.05061189830303192, 0.025414755567908287, -0.042616259306669235, 0.027827449142932892, 0.04215861111879349, 0.09049715101718903, -0.005658895708620548, 0.06800100952386856, 0.02594...
0.061544
.. ipython:: python ser = pd.Series([1., 2., 3.]) ser.loc[0] = None ser ser = pd.Series([pd.Timestamp("2021"), pd.Timestamp("2021")]) ser.iloc[0] = np.nan ser ser = pd.Series([True, False], dtype="boolean[pyarrow]") ser.iloc[0] = None ser For ``object`` types, pandas will use the value given: .. ipython:: python s = pd...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/missing_data.rst
main
pandas
[ -0.05483598634600639, -0.013396751135587692, 0.005956895649433136, 0.023129573091864586, -0.0007872060523368418, -0.06984391063451767, -0.008819268085062504, -0.02306748554110527, 0.026537099853157997, 0.03789801523089409, 0.03754955157637596, -0.0424504354596138, -0.08355412632226944, -0....
0.023548
) df df.interpolate() idx = pd.date\_range("2020-01-01", periods=10, freq="D") data = np.random.default\_rng(2).integers(0, 10, 10).astype(np.float64) ts = pd.Series(data, index=idx) ts.iloc[[1, 2, 5, 6, 9]] = np.nan ts @savefig series\_before\_interpolate.png ts.plot() .. ipython:: python ts.interpolate() @savefig ser...
https://github.com/pandas-dev/pandas/blob/main/doc/source/user_guide/missing_data.rst
main
pandas
[ -0.12002038210630417, -0.03516978397965431, 0.10649880021810532, -0.010465128347277641, 0.03360459581017494, -0.022753970697522163, -0.009178848005831242, 0.06470567733049393, -0.006604554131627083, 0.0213081743568182, -0.044623129069805145, -0.01071680337190628, -0.023827439174056053, -0....
0.052421