alright, I apologize for the dumb question but I would really appreciate some help on this one. I am trying to analyze a cash game I played in, but seem to be having some trouble. I can get the file to open and read but when I reference it to search in it I come up with a lot of issues. The title is the current issue I am having which was implemented because it seemed that it might serve as a solution to another problem I was having. Thanks for any help in advance!
(the natural formatting of each line of code on here didn't translate well so the site is making me link to the paste of the picture instead. The lines of code are still below however.)
#find the nunmeber of hands played in this cash game
import pandas as pd
import os
import pprint
dataDirectory = r'C:\ACR\ACR CASHGAME 10 25.txt'
handHistory = pd.read_csv(dataDirectory, sep='\n')
handHistory = os.path.join(r'C:\ACR\ACR CASHGAME 10 25.txt', handHistory)
#when I remove the line above from the code, it says dataDirectory file does not exist even though it reads it in previous lines fine.
numberofHands = pd.read_csv('dataDirectory',dtype=object)
for key in handhistory:
if handHistory[key] == 'Hand':
numberofHands.count(key)