keplergl / keplergl/kepler.gl

[Bug][Jupyter Widget] Keplergl can't recognized converted float64 column

Open
#1,640 0 comments 0 reactions 1 assignee Claimed by @heshan0131 View on GitHub
jupyter
Dominant language
TypeScript
Stars
12k
Forks
2k
Avg merge
1d 5h
Merged PRs (30d)
66

Description

**Describe the bug**
Keplergl can't recognized converted `float64` column

**To Reproduce**
Steps to reproduce the behavior:
download the dataset from kaggle [=> download link](https://www.kaggle.com/mohitkr05/global-significant-earthquake-database-from-2150bc)
```
df = pd.read_csv('Worldwide-Earthquake-database.csv')
df['LONGITUDE'] = pd.to_numeric(df.LONGITUDE, errors='coerce')
df['LATITUDE'] = pd.to_numeric(df.LATITUDE, errors='coerce')
df['FOCAL_DEPTH'] = pd.to_numeric(df.FOCAL_DEPTH, errors='coerce')
df['EQ_MAG_MW'] = pd.to_numeric(df.EQ_MAG_MW, errors='coerce')

kepler_map = keplergl.KeplerGl()
kepler_map.add_data(data=df, name="earthquakes")
kepler_map
```
As you can see, `FOCAL_DEPTH` and `EQ_MAG_MW` are formated as `string` instead `float64`
![image](https://user-images.githubusercontent.com/60387342/136702112-c75a9732-140a-43e2-98ac-a803abc60053.png)

**Expected behavior**
Keplergl detect automatically column types based on `pandas` dataframe dtypes.
![image](https://user-images.githubusercontent.com/60387342/136701967-14010b9e-52a6-4669-805d-881305828c95.png)

**Environment (please complete the following information):**
- Python version: 3.7.10
- keplergl version : 0.3.2
- jupyterlab version : 3.1.9

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.