MathModule V3 -- make math easier(NEW CLASS TYPES)

wow its awesome

i actually thought of making a math module recently but you took the spot :flushed::disappointed_relieved:

3 Likes

A lot of these things that I feel that Roblox needs. This will come in handy. Thanks!

Although I don’t know a lot of the things on the list, i’m interested to see how you handled to find the mode. I made something like this that found the Median, Mode, Mean, and Mad and had a UI that let you use commands and create tables. Although I only really made it to get out of doing my math hw it was a nice project to expand my skills.

1 Like

I simply used 2 for loops in order to get it working
had to organize it and then calculate it
surprisingly I managed to do it with very little code

That’s a nice module, though some extra features, such as math.average would be very cool to see if you’d ask me.

1 Like

im hoping to have way more features in V2

did you used my setmetatable trick? awesome

1 Like

yep
I just wish I could somehow make the start of the script shorter then 46 lines
if I can im def gonna try that for the next version

isn’t finding the mean the same as finding the average?

Well, you’re correct, but having average as an alias for mean would be cool.

1 Like

so basically a second way of calling the same function
sounds like a great idea

1 Like

With math.mean being added, math.median and math.mode could be added too, differentiating the 3 types of averages. There are cases where you might want to use the last two, such as in population or player data or statistics.

2 Likes

but I already have all those three in there what :joy:

they were talking about how average could do the same thing as math.mean but just a different name

1 Like

Bookmarked. Looks very cool! I will probably be using this

1 Like

thank you, very hype for V2 as well

1 Like

Sorry, I thought the base math library had math.average in it and that was the debate lol. Either way, using “average” for the mean is somewhat incorrect, and the other way standardizes it between the types of averaging.

1 Like

so should I even add a math.average if mean, median, mode, and range are already there?
because that would mean finding the average is just finding one of those 4 making math.average useless

Other libraries I’ve seen in other programming languages don’t use “average” as a function due to ambiguity, and ambiguity is usually a bad thing in programming for programmers, so I think it should be left out, or if it must be there, to take an input of the average type and the table to average, which would result in less performance and be redundant.

1 Like

ok im not gonna add it then
thanks

1 Like

Or you could just make a function to return a table with the 4 functions in use.
Like math.average = {mean = math.mean, median = math.median, ...}

1 Like