jStat is a JavaScript library for statistical operations. It aims to provide a JavaScript-based alternative to MATLAB or R. The documention is unfinished, leaving the range of features unclear. But it’s has potential.
“It’s certainly not a full-fledged stats package in the same sense as R or SPSS or SAS,” says R developer Ed Borasky. “But the trend is clearly towards building statistics and visualization software in JavaScript.” Borasky’s mantra is “Perl is the past, R, Ruby, Python, PHP and Java are the present, and JavaScript is the future.”
Pseudosavant and Sylvester are other mathematics libraries for JavaScript.
There are also numerous libraries for creating charts and visualizations, including DojoX DataChart, Flot and gRaphaël. You can find a list of libraries here.