Forum Documentation Showcase Pricing Learn more

How to use trigonometry like in Excel? (cosine, sine, etc.)


How do I do trig calculations in Bubble?

Can I accomplish this with a plugin? Do I need to learn Javascript?

I’m converting an existing Google Sheet into a web app. The app will import data from an uploaded file, complete various calculations, and display the data in a chart. I could share the entire sheet here if that would help, but here’s an example of one of the functions I would need to replicate in Bubble:


Yeah, fundamental JS would be useful for you in this case, HOWEVER that’s not really necessary, it’s very likely that such can be achieved through the math.js (local) plugin.


Oh, really? My understanding was that MATH.js had no trigonometry, but now I’m looking at the documentation more closely and I see that I include example like
math.eval('cos(45 deg)') // 0.7071067811865476

I wonder why there is no complete list of mathematical functions it support. I guess I’ll need to look into it further. Thank you @vini_brito !