#python graphs
Explore tagged Tumblr posts
chronomally · 2 months ago
Text
Death by a thousand cuts in my class this week
6 notes · View notes
antiparticular · 3 months ago
Text
fighting for my life trying to defend python from computer science students. she's my beautiful wife and she makes lovely graphs, don't insult her
2 notes · View notes
valyrfia · 1 year ago
Note
just read your charles and carlos comparison and am popping by to say it was excellent keep up the good work! also i know latex formatting when i see it...........
Hi anon I'm glad you enjoyed it! I'm giggling that you managed to pick out the latex content from sight.....just for context, I typed those tables up in the main doc of my thesis because it was the most convenient latex compiling tool I had open at the time...truly a woman in STEM moment if I may say so myself.
14 notes · View notes
theresa-of-liechtenstein · 1 year ago
Text
every time i try to put a god damned legend on this graph with seven lines on it my laptop literally freezes for minutes at a time so i can only click one thing before it goes non-responsive again. which is pretty much a great summary of how this stupid capstone project is going.
5 notes · View notes
thesecondface · 4 months ago
Text
third year of the phd and this is the first time i'm implementing functional programming. what have I been DOING until now
1 note · View note
aesthetic-uni · 4 months ago
Text
Me when I manage to bypass the obstacles the interface has placed on me and finally gain access to the forbidden texts
(I wasn’t able to install pandas and it took me an hours and multiple YouTube videos to find the problem and just change one property)
Tumblr media
0 notes
flamagenitus · 7 months ago
Text
I was looking at the computer science curriculum for 1st year comp sci at my university and as a bioinformatics student the comparison is insane. Ppl who have choose comp sci for their degree have like 4 months to learn how python works where we have 1. They are not taught 4 programming languages per year. They are allowed to acclimatise to the notion that packages exist and sometimes they contain useful functions you don't have to create yourself!
AND YET, WHEN A BIOLOGY PERSON CAN'T INSTANTLY USE PYTHON 1 MONTH INTO A BIOINFORMATICS DEGREE, WE ARE CALLED 'BAD AT PROGRAMMING' --
0 notes
wh40kdr · 11 months ago
Text
Devlog 1 - Basic Dice Function (and relevant statistics) (14:17 DST 14/06/2024)
To kickstart my journey let's talk about my dice-rolling function and some very basic and important statistics about fair dice and dice rolls. The core function of any dice-rolling app for any game is the ability to roll fair dice. A six-sided dice (d6 in TTRPG lingo) should give each possible result (i.e. any number from 1-6) 1/6th of the time it is rolled. In principle if you roll the dice six times you should get six different results: 1, 2, 3, 4, 5, and 6. Then if you roll the dice a seventh time you should get a repeat result. Now in practice this won't happen for a small quantity of dice rolls, because the result of a fair dice is random, and so instead the fairness is measure over many, many dice rolls, until eventually it can be said that the dice is fair. Let's consider the actual dice function and how it works. Creating a dice roller is actually rather simple. I made mine by defining a callable function called roll(), with a number of sides that could be inputted (and has a default value of 6 since the purpose of this roller will be for Warhammer). The function then uses a random number generator to generate a number, n, where 0 <= n < 1 (a number between zero and one which could be zero but can't be one). The random number is multiplied by the number of sides which gives a floating point number.
Now for some python syntax. Python contains an in-built function called int(), which converts floating point numbers into integer numbers. It does this through truncation i.e. 0.2 -> 0, 1.4 -> 1, 2.9 -> 2. So our integer result takes a value between 0 and the number of sides minus 1 (for a six-sided dice right now we get 0, 1, 2, 3, 4, or 5). To get valid results for any sided dice we then just add 1 to the random result.
Tumblr media
Figure 1. The above shows a histogram of the results of 50 dice rolls before the +1 shift. (Disclaimer: The numbers on the x-axis for all graphs are a mess. Ignore them, each column represents an integer value.)
Tumblr media
Figure 2. The above shows another histogram of the results of 50 dice rolls this time with the +1 shift. The results are now valid for a d6.
So we have a dice roll function and now we come back to the earlier part of this Devlog, is it fair? Testing this is relatively easy. For a fair dice, if we plot a histogram of a large number of dice rolls (say 5 million), then the resulting graph should show a uniform distribution.
Tumblr media
Figure 3. The distribution of results from 5 million dice rolls.
Since this distribution is uniform (there will be fluctuations in each column but they're statistically insignificant when each column contains 800,000+) the dice is fair. But before I sign off this Devlog, lets show one more cool thing about dice. Rolling two dice of the same type (say 2d6) and summing the results gives a normal distribution.
Tumblr media
Figure 4. The distribution of 50 million 2d6 rolls.
For anyone wondering why this is cool, this is a little nerdy homage of mine and part of the reason I originally created a dice roller. One of my favourite Dungeons and Dragons youtubers is Matt Colville, who runs a very interesting youtube series called running the game, which teaches people how to Dungeon master. He's also started a board game company spinning off from the channels success who are creating their own TTRPG (which I'm very excited to play). They did a very interesting video about dice a few months ago in which Matt claimed that the result of 2d6 was normally distributed, and me being a nerd I decided I would experimentally test that claim myself rather than taking it on a face value. The result is the original dice roll function and most of the subject of this Devlog. So thank you Matt and the entire team at MCDM.
As a final sign-off from me, I will be uploading the master python file to my GitHub: https://github.com/SamFuller02/WH40kDR. At the moment I'm still figuring out GitHub so for now it may appear a little sloppy but it might improve with time.
Link to the video that inspired me: https://www.youtube.com/watch?v=lvs2OYsJmaY
1 note · View note
quickinsights · 11 months ago
Text
0 notes
antiparticular · 13 days ago
Text
I (physics student) just helped my computer science student friend with her coding????
0 notes
nougatbit · 1 year ago
Text
today i used the fancy graphing calulator (not for graphing but oh well) the last time i needed that thing was 4 years ago...
1 note · View note
i-shall-not-show-mercy · 2 years ago
Text
Bored at work. I just wanna do stats on my own ocs. Let me.
0 notes
morfanerina · 2 years ago
Text
Trying to make my graph's legends in matplotlib be consistent is so hard. Why is it that I put the location as lower right it put the legend box on top of the graph???
Screw you matplolib
0 notes
avertigo · 2 years ago
Text
Create charts in ChatGPT in seconds
Charts are an essential tool in data analysis and information visualization. They allow to visually represent the relationship between different variables and facilitate the understanding of patterns, trends and comparisons. In addition, graphics can convey complex information clearly and concisely, making them a valuable communication tool. In the context of learning Python, creating charts is…
Tumblr media
View On WordPress
0 notes
origamiiscool · 1 year ago
Text
Did you know you make animations on matplotlib. It blue my mind to realize that and now that I've got a decent grasp on animating plots on matplotlib I can't stop animating any of my plots
Tumblr media
60 notes · View notes
sprinklecipher · 10 hours ago
Text
How much dialogue there is in the mainline Ace Attorney games
I made some graphs about how much dialogue there is across the "mainline" Ace Attorney games (AA1-AA6):
Tumblr media Tumblr media
graphs split out by episode/character + data notes below the cut
Total Dialogue by Episode (game order)
Tumblr media
Total Dialogue by Episode (length order)
Tumblr media
Total Dialogue by Character
Tumblr media
Overall, there's over 1.5 million words of dialogue across the mainline AA games (about 1,570,000 words, by my count)
Data source: I’m using a dataset that I put together pulling from the episode transcripts on the Ace Attorney wiki (which I did almost entirely via Python, but with a bit of manual cleanup). There’s bound to be some error resulting from that process, but the numbers should be pretty close.
63 notes · View notes