<jupyter_start><jupyter_text>Sélection des données<jupyter_code>import pandas as pd
chemin = 'assets/artistes_data.csv'
df = pd.read_csv(chemin) #dataFrame
df.head(3) #affiche les n premiers enregistrements

df.dtypes
df2 = df.Fortune.astype(str)
df2.dtypes
df.dtypes
df2 = pd.to_numeric(df.Fortune)
df2.dtypes<jupyter_output><empty_output><jupyter_text>Conversion float en int<jupyter_code>df2 = df.Fortune.astype(int)
display(df.dtypes)
display(df2.dtypes)
df.Fortune = df.Fortune.astype(int)
df.to_csv('assets/fortuneInt.csv')
df.dtypes<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.12478031634446397, 'fraction_numerical': 0.012302284710017574, 'mean_word_length': 7.769230769230769, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '302145', 'license': 'MIT', 'n_tokens_mistral': 250, 'n_tokens_neox': 245, 'n_words': 35, 'path': 'Jour 4/08 Selection des donnees.ipynb', 'repo_name': 'bellash13/SmartAcademyPython', 'size': '569'}