nlmixr2 / nonmem2rx

nonmem2rx
https://nlmixr2.github.io/nonmem2rx/
9 stars 0 forks source link

Parse error for data ignore statement with numerical equality test #173

Closed PharmetheusHenrikN closed 3 months ago

PharmetheusHenrikN commented 3 months ago

Hi there! I noticed an issue for models with numerical comparison instead of character comparison (.EQN.) in the $DATA ignore statements:

$DATA syntax error:
:002:             IGNORE=@ IGNORE(BLQ.EQN.1)
                                     ^

I assume there needs to be an eqn_expression_nm defined in the C.

mattfidler commented 3 months ago

Is .EQN. equivalent to .EQ. I'm afraid I don't know the difference. If I don't know the difference, I cannot implement it

mattfidler commented 3 months ago

Ah, you say it is for numerical comparison. I must say that .eq. works for character comparison and numeric comparison in NONMEM so I didn't know there was another operator.

I will add this to the grammer.

mattfidler commented 3 months ago

Fixed in edded16

mattfidler commented 3 months ago

I also see you mention eqn_expression_nm which is where it is changed in the grammar files.

Note by simply doing devtools::document() it updates the C for simple fixes like this one.

PharmetheusHenrikN commented 3 months ago

That's excellent, thank you for the fast turnaround!

mattfidler commented 3 months ago

No problem