PK_Lover ☆ Portugal, 2014-11-21 01:28 (3808 d 05:21 ago) Posting: # 13895 Views: 20,120 |
|
Hello all, I am trying BEAR for the first time for a simple NCA and ANOVA analysis for a 2x2x2 BE study data. I have arranged all the data in a .csv file with subj,seq,perd,time,conc and I have maintained T0=0 and all the other LLOQ (either at the start of the schedule or at the end) as NA. I ran BEAR, import the file, the values appear correctly in the table. It starts the analysis, it shows some pk values but then states: Error in lm.fit(x, y, offset = offset, singular.ok = singular.ok, ...) : and crashes. I have checked all the data, seems ok. Could you please help me and tell me whats wrong? Thank you! |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2014-11-21 08:34 (3807 d 22:15 ago) (edited on 2014-11-21 11:05) @ PK_Lover Posting: # 13898 Views: 17,869 |
|
Dear PK_Lover, Could you post the setting content from R console here after running 'go()' at the beginning? Something like:
------------------- Current settings ------------------ Is your analysis using the partial or truncated AUC (pAUC) with multiple-dosed? If yes, please make sure that pAUC_start and pAUC_end should count from the time of starting dose (i.e., time = 0.), not within one dosing interval. If not, please turn pAUC off (= 0). Sorry about this error. ❝ [...] ❝ I ran BEAR, import the file, the values appear correctly in the table. It starts the analysis, it shows some pk values but then states: ❝ ❝ Error in lm.fit(x, y, offset = offset, singular.ok = singular.ok, ...) : ❝ NA/NaN/Inf in 'y' ❝ ❝ and crashes. I have checked all the data, seems ok. ❝ [...] — All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
PK_Lover ☆ Portugal, 2014-11-22 01:07 (3807 d 05:42 ago) @ yjlee168 Posting: # 13911 Views: 17,649 |
|
Dear yjlee168, thank you very much for your quick reply (I am honored!). I am sorry for not replying earlier but I did not have access to the station where I have R installed until now. Here is the setup (it is the default): Methods Setting which_is 1 run demo? 0 no 2 study design? 0 2x2x2 crossover 3 single-/multiple-dose 0 single-dose 4 lambda_z estimate 0 adj. R sq. (ARS) 5 trapezoidal AUC 0 linear-up/log-down 6 BE criterion (LL) 80 lower limit 7 ODA? 0 no 8 dose? 100000 dose given 9 dosing interval 24 *multiple-dose only 10 Tlast 120 *multiple-dose only 11 pAUC? 0 all AUC 12 pAUC_start 121 the starting time of pAUC 13 pAUC_end 128 the end time of pAUC 14 IDP output? 0 no The plot label of x-axis -> Time after Dosing (hr) and the label of y-axis -> DrugX Plasma Conc. (ng/mL) And I am using data from a simple Crossover design with 2 periods, single administration. |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2014-11-22 04:21 (3807 d 02:28 ago) @ PK_Lover Posting: # 13912 Views: 17,657 |
|
Dear PK_Lover, Do you use the default setting to analyze your data? I think the error is due to failure to find a lambda_z during NCA (invalid 'y' when doing linear regression). If the error still persists, please check your data carefully. Or try to switch lambda_z estimation method to 'Select 2-6 data points manually' (lambda_z estimation = 5) instead of using the default of 'Adjusted R sq. (ARS).' By the way, manual data point selection may also provide you a chance to check subjects' data individually. Hope this can help. ❝ [...] ❝ And I am using data from a simple Crossover design with 2 periods, single administration. — All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
PK_Lover ☆ Portugal, 2014-11-22 10:47 (3806 d 20:02 ago) (edited on 2014-11-22 11:18) @ yjlee168 Posting: # 13913 Views: 17,635 |
|
Dear yjlee168, Yes, I think that is a possibility since I have some LLOQ points for the last collections. I will try it manually and then will let the forum know if it worked ok. Thank you very much! EDIT: It worked like a charm! NCA and ANOVA done! Thanks a lot! I should change my nickname to BEAR_Lover! :) |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2014-12-01 09:13 (3797 d 21:36 ago) @ PK_Lover Posting: # 13959 Views: 17,445 |
|
Dear PK_Lover, Great to hear that everything was going fine. Since I like to alert users about the error as you had, I have bear v2.6.4 (pre-release) ready to release. Unfortunately, I cannot reproduce the data set to test it. Could you please help (only when you are available; no rush at all) me to test bear? If you can, please download bear v2.6.4 from my wuala cloud storage here (bear_2.6.4.zip). Then set lambda_z estimation as ARS (or TTTARS, TTT, AIC, TTTAIC?) with your data set. See install.txt if you need to know how to install it. It is not a beforehand check-up for all subject's data points first, but will show a warning message before the crash message when dealing with invalid 'y'. Thanks in advanced. ❝ ... EDIT: It worked like a charm! NCA and ANOVA done! Thanks a lot! I should change my nickname to BEAR_Lover! :)— All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
Emrah Soner Özdeş ☆ Turkey, 2015-01-15 15:37 (3752 d 15:12 ago) @ yjlee168 Posting: # 14293 Views: 17,011 |
|
Dear yjlee168; First of all I need to say that I am grateful for you guys for developing such a useful tool for BE/BA studies. Currently I have the latest version of both R and the BEAR package. I am having the same issue mentioned in the first messaga of the thread. It runs smooth until the 16th subject and stops in the 17th subjects, probably because of a BLOQ value in subject 17. The workaround of manual selection of points worked fine with me. But as you guess it is not very practical and time consuming. I used to use WNL for NCA analysis, and have the feeling of the method of WNL for Lambdaz calculation (Rsq adjusted) is the most reliable one (I never tried the other methods). So is there any other solution to this problem other than manuel selection ? I found the solution before your reply. I just replaced BLOQ values at the end with "NA" and it worked like a magic. Got the hint from: http://pkpd.kmu.edu.tw/bear/ Best Regards Emrah Soner Özdeş Edit: Merged with a follow-up post. You can edit your original post for 24 hours. [Helmut] |
Jam ☆ UK, 2015-01-23 09:55 (3744 d 20:54 ago) @ Emrah Soner Özdeş Posting: # 14314 Views: 16,749 |
|
I get the same problem when profiles have zero values towards the end of the profile. Also, I found my version of Excel (2013) produces CSV files with a comma at the end of each line. This seems to cause Bear to misread the CSV files. Nevertheless I very much appreciate having the package. Jam Edit: Full quote removed. Please delete everything from the text of the original poster which is not necessary in understanding your answer; see also this post! [Ohlbe] |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2015-01-25 05:35 (3743 d 01:13 ago) @ Jam Posting: # 14319 Views: 16,719 |
|
Dear Jam, Thanks for using bear and your interesting messages. But I don't quite understand why is 'CSV files with a comma at the end of each line.' Is it normal for MS-Excel 2013 to produce a csv that way? Or did you have extra settings to save/export that kind of csv from Excel 2013? It sounds like that Excel is treated your dataset as if there is still data after the end of each row. — All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
xtianbadillo ☆ Mexico, 2016-09-16 00:44 (3143 d 07:05 ago) @ yjlee168 Posting: # 16646 Views: 14,260 |
|
Dear yjlee168 I had the same problem, thanks to your contribution, I changed the default settings as you said and the issue was solved. ❝ Do you use the default setting to analyze your data? I think the error is due to failure to find a lambda_z during NCA (invalid 'y' when doing linear regression). If the error still persists, please check your data carefully. Or try to switch lambda_z estimation method to 'Select 2-6 data points manually' (lambda_z estimation = 5) instead of using the default of 'Adjusted R sq. (ARS).' By the way, manual data point selection may also provide you a chance to check subjects' data individually. Hope this can help. Edit: Full quote removed. Please delete everything from the text of the original poster which is not necessary in understanding your answer; see also this post #5! [Helmut] |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2016-09-16 11:42 (3142 d 20:07 ago) (edited on 2016-09-16 18:00) @ xtianbadillo Posting: # 16647 Views: 14,276 |
|
Dear xtianbadillo, I wonder that you are using the previous version of bear. I have already fixed the error since v2.7.1. Now it's v2.7.7. The error comes from that the data point selection method (such as ARS) fails to select at least three data points after Cmax to estimate λz. Thus, there is no drug plasma conc. (i.e., 'y') selected at all. That's what the error messages tell us. In other words, you may have at least one subject who had insufficient data points (≧ 3 data points after Cmax) to estimate λz. May I know what version of bear you used? You can upgrade bear from Sourceforge if you like (not on CRAN any more; very sorry about that). And try it again with the same dataset using ARS or others. It will tell you which subjects get involved with insufficient data points. Hope this can help. ❝ ...I changed the default settings as you said and the issue was solved. — All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
VStus ★ Poland, 2016-09-26 15:30 (3132 d 16:19 ago) @ yjlee168 Posting: # 16684 Views: 13,862 |
|
Dear yjlee168, ❝ The error comes from that the data point selection method (such as ARS) In 2.7.7 I've got an error trying to process a dataset from multiple-dose trial, regardless of the fact that I've selected 'multiple dose' in config. Is there a way to turn-off assessment of elimination parameters for multiple dose trials? I wanted to recalculate AUCtau and confirm Cmax and Cmin values after switching to originally obtained concentrations. 'R.split[[j]]':index outside of borders |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2016-09-26 20:04 (3132 d 11:45 ago) @ VStus Posting: # 16685 Views: 13,813 |
|
Dear VStus, The error sounds like that bear import null data points to analyze. Do you set proper values for both the dosing interval and Tlast (the time of the last dose given counted from time zero) with a multiple-dosed study (check with the cheat-sheet for bear setup)? If you worry about the data points for λz, you can switch to manual selection. However, the function of estimating λz cannot be turned off. Hope this can help. Good luck.❝ ... ❝ — All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
VStus ★ Poland, 2016-10-11 11:01 (3117 d 20:48 ago) @ yjlee168 Posting: # 16715 Views: 13,663 |
|
Dear Yung-jin Lee, I'm finally back to the topic of multiple dose studies in bear. I've switched locale of error messages to English, so there will be no translation errors. So yes, with the config I assume to be correct for multiple-dose study and standard Lambda_z assessment:
----------------- Current settings ---------------- I'm getting the same error:
Warning: Next to save all linear regression plots for λz estimation. So, I change setup to select points manually and stuck with another issue: blank graph. ![]() And, finally, error and halt of bear when I select stop for the graph: **************************************************************************** It worked for me somehow previously (maybe previous version of bear?). Maybe I'll dig into the code to just avoid estimation of elimination parameters for multiple dose studies? Thank you very much in advance! I use bear from time to time for my work and it's very helpful!Regards, VStus |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2016-10-11 12:15 (3117 d 19:34 ago) @ VStus Posting: # 16718 Views: 13,682 |
|
Dear Vstus, I just run the demo of multiple-dose with bear. It is ok. Please make sure that your Tlast is set correctly (the dosing interval looks fine). For example, the following case has Tlast = 120 and dosing interval = 24.
Time conc. BTW, in your setting why dose (mg)? dose ? The dose should be numeric in the unit of mg.— All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |
VStus ★ Poland, 2016-10-11 12:37 (3117 d 19:12 ago) @ yjlee168 Posting: # 16720 Views: 13,562 |
|
Dear Yung-jin Lee, ❝ Please make sure that your Tlast is set correctly (the dosing interval looks fine). For example, the following case has Tlast = 120 and dosing interval = 24. My dataset includes only concentrations obtained during last (7th) day of treatment period. Last tablet was given on 7th day (that's why I've entered 168 hrs). Sampling is 24 hrs (for dosing period-only). Change of Tlast to 120 not helps. My understanding is that I should add pre-steady state samples. Correct? ❝ BTW, in your setting why I've removed it intentionally from post to avoid breaking NDA :) Regards, VStus |
VStus ★ Poland, 2016-10-12 12:37 (3116 d 19:12 ago) @ yjlee168 Posting: # 16726 Views: 13,746 |
|
Dear Yung-jin Lee, Thank you very much for your help! It appeared that my dataset was buggy. After corrections and manual selection of timepoints for elimination it finally worked. Regards, VStus |
yjlee168 ★★★ ![]() ![]() Kaohsiung, Taiwan, 2016-10-12 20:42 (3116 d 11:06 ago) @ VStus Posting: # 16727 Views: 13,400 |
|
Dear VStus, Great and very happy to know that the problem has been solved. Have a a nice day. — All the best, -- Yung-jin Lee bear v2.9.2:- created by Hsin-ya Lee & Yung-jin Lee Kaohsiung, Taiwan https://www.pkpd168.com/bear Download link (updated) -> here |