HP PPL and Statistical distributions
|
05-18-2021, 03:38 PM
Post: #6
|
|||
|
|||
RE: HP PPL and Statistical distributions
(04-13-2021 08:18 PM)compaqdrew Wrote: The trick will be the infinite integration limits. This is indeed the case. Recently, we discussed tanh-sinh, exp-sinh, sinh-sinh algorithm here Combined as 1, we have quad (my Lua implementation here, emace67 double_exponential.py here). First, I clean-up CAS code, and run in XCas (s lower limit changed to 0. produced some speed-up) Code: Studentized_Range_q_P_Value(q,k,ν):= Picked an example, from studentized-range-q-table From first page, P-value = 0.10, k=8, df=12, we have q = 4.511 XCas> Studentized_Range_q_P_Value(4.511, 8, 12) Evaluation time: 6.24, returned 0.100017379207 Now, rewrite code in lua, using quad to integrate. Code: do lua> Studentized_Range_q_P_Value(4.511, 8, 12) 0.10001737920797527 We got the same answer ... But, LuaJIT take 0.003 second |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)