Skip to content

Commit

Permalink
Wed, Aug 7, 2024, 9:01 AM +03:00
Browse files Browse the repository at this point in the history
  • Loading branch information
AbdoullahBougataya committed Aug 7, 2024
1 parent 476ea22 commit 7609b56
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
Binary file modified __pycache__/scrapper.cpython-311.pyc
Binary file not shown.
3 changes: 1 addition & 2 deletions scrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,7 @@ def scrapper():
# Change Thrusts intervals to medians
if string_element.find('–') != -1:
row += tuple(map(float, [(float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ").split()[0].split('–')[0]) + float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ").split()[0].split('–')[1])) / 2, (float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ").split()[1].split('–')[0]) + float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ").split()[1].split('–')[1])) / 2]))
elif i == 21:
row += tuple(map(float, [float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ")[0:7]), float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ")[7:13])]))
###
else:
row += tuple(map(float, [float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ").split()[0]), float(re.sub("\(.*?\)","()", string_element).replace("()", "").replace(" ", " ").split()[1])]))
# Change numbers from strings to floats
Expand Down

0 comments on commit 7609b56

Please sign in to comment.