This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Simple linear regression | |
* | |
* @param {Array.<number>} data | |
* @return {Function} | |
*/ | |
function regression(data) { | |
var sum_x = 0, sum_y = 0 | |
, sum_xy = 0, sum_xx = 0 | |
, count = 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<p style="width: 70%;margin: auto;margin-top: 5%;font-size:larger;text-align:center"> | |
Download a file from any URL</p> | |
<form method="post" style="width: 70%;margin: auto;margin-top: 10%;"> | |
<input name="url" size="50" placeholder="Source URL" style="width: 100%;height: 10%;font-size: 1.5em;padding:10px" required> | |
<input name="submit" type="submit" value="Download" style="width: 30%;height: 10%;margin: 5% auto; display: block;"> | |
<p style="width: 70%;margin: auto;margin-top: 10%;font-size:larger;text-align:center"> | |
To <?php echo getcwd(); ?></p> | |
<p style="width: 70%;margin: auto;font-size: smaller;text-align: center;position: fixed;bottom: 0;background: #fff;"> | |
Powered by: <a href="https://karthikbhat.net/portfolio" target="_blank" style="color:#f60;text-decoration:none;">Karthik</a></p> |