Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Getting 'ValueError'

Soham1087

Banned
Joined
May 31, 2022
Messages
17
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Location
India
Activity points
185
The input contains NaN, infinity, or a value too large for dtype('float64')' when trying to perform a group by operation on my DataFrame. Here's my code snippet:

Python:
import pandas as pd

# Load data from CSV
data = pd.read_csv('data.csv')

# Perform groupby operation
grouped = data.groupby('category')['value'].sum()

I've checked for NaN or infinity values in 'value' column using data['value'].isnull().sum() and data['value'].isinf().sum() which both returned 0. What could be causing this error and how can I resolve it?
 

LaTeX Commands Quick-Menu:

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top