system.time question
You asked several questions.
Elapsed: yes
User + System = CPU: yes
Finally: You have to look at the load and/or cpu core count. Unless you setup your code to take advantage of multiple cores, R runs on a single core.
Also: Do you really need to ask that question?
---------------------------------------------------------------------------
Jeff Newmiller The ..... ..... Go Live...
DCN:<jdnewmil at dcn.davis.ca.us> Basics: ##.#. ##.#. Live Go...
Live: OO#.. Dead: OO#.. Playing
Research Engineer (Solar/Batteries O.O#. #.O#. with
/Software/Embedded Controllers) .OO#. .OO#. rocks...1k
---------------------------------------------------------------------------
Sent from my phone. Please excuse my brevity.
Mark Leeds <markleeds2 at gmail.com> wrote:
Hi : I looked at the help for system.time but I still have the following question. Can someone explain the output following output of system.time : user system elapsed 12399.681 5632.352 56935.647 Here's my take based on the fact that I was doing ps -aux | grep R off and on and the total amount of CPU minutes that got allotted before the job ended was about 5 hours and the total actual time that the job took was about 15 hours. Does elapsed = total actual time job taken ? That seems to be the case or a strange coincidence. Does user + system = CPU time from ps -aux | grep R ? That seems to be the case also or a weird coincidence. Finally, why can't the CPU get a higher percentage ? It's seems like it's always around 30% which would make sense since 5 is ~ 30% of 15 hours. Also, assuming my take above is correct, when talking about timing of algorithms, in this case, does one say the job took 5 hours or 15 hours ? I'm trying to see how fast an algorithm is compared to others and I'm not sure what the standard is. I'm on fedora 16.0 and using R 2.15. Thanks. [[alternative HTML version deleted]]
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.