Focal Point
[CASE OPENED] Issues with Load type and long arithmatical formulas

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/1381057331/m/4467021196

February 19, 2019, 08:46 PM
Max Nevill
[CASE OPENED] Issues with Load type and long arithmatical formulas
Hi All. I've run a regression model on some data in R that I want predictions for. I've input the following defines into the DMC:


DEFINE PROB1/D12.8=-858.42301
-3.719857*ADMIT_CONDITION
-1.940163*AGE
+0.001839*AGE*INDIA
-3.294986*CHINA
+8.969689*CIS_DEG
-18.19678*CIS_DEG*COMPLIANCE
+20.924397*COMPLIANCE
+4.252925*ELPV_060
-3.109407*ELPV_070
-18.488914*ELPV_080
-35.315861*ELPV_100
+2.209021*ELPV_100*AGE
+8.477627*ELPV_100*CIS_DEG
+3.806944*FALL
+179.00265*FIRST_DAY_TO_APP_TIME
-1.467934*GENDER1
+25.041572*HS_GRAD
-14.409795*FIRST_DAY_TO_APP_TIME**2
+0.504913*FIRST_DAY_TO_APP_TIME**3
-0.006499*FIRST_DAY_TO_APP_TIME**4
+20.793924*IN_PROGRESS
+0.13704*INDIA
+26.45438*OTHER_ADMIT
+23.891475*POST_SEC
+3.479564*WINTER; $
DEFINE PROB2/D12.8=IF AGENT_TYPE EQ 'General Agents' THEN -0.668142 ELSE
IF AGENT_TYPE EQ 'Pending Agent' THEN 14.195363 ELSE
IF AGENT_TYPE EQ 'Sub-agent' THEN 22.703964 ELSE
IF AGENT_TYPE EQ 'Unknown' THEN 34.893819 ELSE 0; $
DEFINE PROBABILITY/D12.8 =EXP(PROB1+PROB2,'D12.8')/(1+EXP(PROB1+PROB2,'D12.8')); $

If I use the Bulk loader, I get the following error:

ORA-01722: invalid number
Record 4: Rejected - Error on table PROJECTIONS_12_MONTHS_OUT, column PROBABILITY

If I use the Insert Records from Memory option, I get wrong answers. I get correct answers in excel, to double check.

If I use Insert/Update, I the PROBABILITY field is just 0 everywhere.

Any thoughts on what I can do to fix this?

This message has been edited. Last edited by: FP Mod Chuck,


WebFocus 8.104
Windows 7 Entreprise, SP1
February 20, 2019, 01:12 PM
FP Mod Chuck
Max

The DEFINE for PROB1 looks incorrect to me. You have numbers and alpha all strung together for a D12.8 field.


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
February 20, 2019, 03:17 PM
Max Nevill
Hi Chuck,

The fields called are all I1 format, with the exception of AGE and FIRST_DAY_TO_APP_TIME, which use the D12.2 format.

Both PROB1 and PROB2 don't (seem) to have any issues in the DMC. (No error flags or messages from those defines.)


WebFocus 8.104
Windows 7 Entreprise, SP1
February 22, 2019, 10:25 AM
FP Mod Chuck
Max

I don't have an answer for you, I suggest you open a case with techsupport.


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
February 25, 2019, 12:48 PM
Max Nevill
quote:
Originally posted by FP Mod Chuck:
Max

I don't have an answer for you, I suggest you open a case with techsupport.


Chuck, I have. Thank you for trying to help!


WebFocus 8.104
Windows 7 Entreprise, SP1
February 27, 2019, 03:13 AM
Frans
Which other fields do you have in your table? It could be that a text field contains a delimiter and messes up the file layout.

Could you try to load only the numeric data? Or load to a text file and see it it's right there?


Test: WF 8.2
Prod: WF 8.2
DB: Progress, REST, IBM UniVerse/UniData, SQLServer, MySQL, PostgreSQL, Oracle, Greenplum, Athena.