Skip to content

Instantly share code, notes, and snippets.

View cooneycw's full-sized avatar
💭
Working to learn Ubuntu 18.04 environments.

cooneycw

💭
Working to learn Ubuntu 18.04 environments.
View GitHub Profile
# install uv tool in windows
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
# install python using uv
uv python install
# install spyder (editor) using uv
uv pip install spyder
@cooneycw
cooneycw / sample_code_to_load_dataframes.txt
Last active April 23, 2025 23:34
Python starter code
import pandas as pd
url_spotify = "https://gist.githubusercontent.com/cooneycw/b4021d5d872ee4a07239f0ea25c23cd7/raw/spotify_data.csv"
url_nba_stats = "https://gist.githubusercontent.com/cooneycw/a90ce2c2adf1208cfc6359c4fa83d928/raw/nba_stats.csv"
# Read the CSV directly into a pandas DataFrame
df_spotify = pd.read_csv(url_spotify)
df_nba_stats = pd.read_csv(url_nba_stats)
# Now you can work with the data
@cooneycw
cooneycw / nhlapi_example.txt
Last active April 23, 2025 18:37
Example of nhl api:
https://api-web.nhle.com/v1/player/8478402/game-log/20232024/2
We can't make this file beautiful and searchable because it's too large.
Track,Album Name,Artist,Release Date,ISRC,All Time Rank,Track Score,Spotify Streams,Spotify Playlist Count,Spotify Playlist Reach,Spotify Popularity,YouTube Views,YouTube Likes,TikTok Posts,TikTok Likes,TikTok Views,YouTube Playlist Reach,Apple Music Playlist Count,AirPlay Spins,SiriusXM Spins,Deezer Playlist Count,Deezer Playlist Reach,Amazon Playlist Count,Pandora Streams,Pandora Track Stations,Soundcloud Streams,Shazam Counts,TIDAL Popularity,Explicit Track
MILLION DOLLAR BABY,Million Dollar Baby - Single,Tommy Richman,4/26/2024,QM24S2402528,1,725.4,"390,470,936","30,716","196,631,588",92,"84,274,754","1,713,126","5,767,700","651,565,900","5,332,281,936","150,597,040",210,"40,975",684,62,"17,598,718",114,"18,004,655","22,931","4,818,457","2,669,262",,0
We can't make this file beautiful and searchable because it's too large.
,player_name,team_abbreviation,age,player_height,player_weight,college,country,draft_year,draft_round,draft_number,gp,pts,reb,ast,net_rating,oreb_pct,dreb_pct,usg_pct,ts_pct,ast_pct,season
0,Randy Livingston,HOU,22.0,193.04,94.800728,Louisiana State,USA,1996,2,42,64,3.9,1.5,2.4,0.3,0.042,0.071,0.16899999999999998,0.48700000000000004,0.248,1996-97
1,Gaylon Nickerson,WAS,28.0,190.5,86.18248,Northwestern Oklahoma,USA,1994,2,34,4,3.8,1.3,0.3,8.9,0.03,0.111,0.174,0.49700000000000005,0.043,1996-97
2,George Lynch,VAN,26.0,203.2,103.418976,North Carolina,USA,1993,1,12,41,8.3,6.4,1.9,-8.2,0.106,0.185,0.175,0.512,0.125,1996-97
3,George McCloud,LAL,30.0,203.2,102.0582,Florida State,USA,1989,1,7,64,10.2,2.8,1.7,-2.7,0.027000000000000003,0.111,0.20600000000000002,0.527,0.125,1996-97
4,George Zidek,DEN,23.0,213.36,119.74828799999999,UCLA,USA,1995,1,22,52,2.8,1.7,0.3,-14.1,0.102,0.16899999999999998,0.195,0.5,0.064,1996-97