3 Replies - 568 Views - Last Post: 30 August 2013 - 07:25 AM

#1 CTphpnwb  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3001
  • View blog
  • Posts: 10,393
  • Joined: 08-August 08

Calculating an Efficient Frontier

Posted 29 August 2013 - 08:44 PM

I have code I've written in C++ to calculate efficient frontiers. it works well but I need to add this ability to a web site, so I'd like to do it in Javascript. The problem is that in some cases there will be a large number of data points. so many that the C++ code can take up to an hour to run. I'm sure Javascript will take much longer, but some of our users may be willing to wait. The problem is that I need to make it easy for them to run this. I can't ask people to change their Javascript settings (dom.max_script_run_time). Is it possible to change it temporarily from within the script?

Is This A Good Question/Topic? 0
  • +

Replies To: Calculating an Efficient Frontier

#2 laytonsdad  Icon User is offline

  • Cheese and Sprinkles
  • member icon

Reputation: 441
  • View blog
  • Posts: 1,870
  • Joined: 30-April 10

Re: Calculating an Efficient Frontier

Posted 29 August 2013 - 09:01 PM

As far as I know changing the dom.max_script_run_time is not possible with javascript code. I hope that I am not misleading you, someone else may know more than I on this though.
Was This Post Helpful? 0
  • +
  • -

#3 Dormilich  Icon User is offline

  • 痛覚残留
  • member icon

Reputation: 3541
  • View blog
  • Posts: 10,259
  • Joined: 08-June 10

Re: Calculating an Efficient Frontier

Posted 29 August 2013 - 11:56 PM

for computationally intense task you can use a WebWorker to do JS calculations in the "background" without affecting the website’s responsiveness. though I can’t tell what execution time limit these have.
Was This Post Helpful? 2
  • +
  • -

#4 CTphpnwb  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3001
  • View blog
  • Posts: 10,393
  • Joined: 08-August 08

Re: Calculating an Efficient Frontier

Posted 30 August 2013 - 07:25 AM

Thanks. I'll report back if I find a time limit.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1