Solved

Attributes with Parenthesis Not Read Correctly?

  • 19 February 2016
  • 5 replies
  • 2 views

I have an attribute creator running to replace missing values with "NA" in a dataset. I noticed however that if the attribute had parenthesis (e.g. "Actual Values (oct-dec)") would replace every value with "NA" regardless of whether it was missing. Removing the "(oct-dec)" from the attribute name, however, returned the desired result. Can anyone else confirm this or had this experience?

icon

Best answer by mark2atsafe 19 February 2016, 21:35

View original

5 replies

Userlevel 2
Badge +16

Maybe off-topic but for replacing empty values the NullAttributeMapper is an excelent choice. It lets you choose any number of attributes and the replacement value in one transformer.

Userlevel 4
Badge +25

I can't recreate this (in 2016.0). What functionality are you using in the AttributeCreator? Conditional values? If so, what is the test? Attribute is Empty? Attribute has Value (not)? Attribute=""?

If you can post a small example workspace it would help a lot.

I can't recreate this (in 2016.0). What functionality are you using in the AttributeCreator? Conditional values? If so, what is the test? Attribute is Empty? Attribute has Value (not)? Attribute=""?

If you can post a small example workspace it would help a lot.

I am using a conditional value. I am attaching a small workflow and a snapshot of the -csv- (can't upload csv's I guess - excel file then) I am using. test.fmw actualvalue.xlsx

Userlevel 4
Badge +25

OK, I can see what is happening, there is a fault in the gui and it is causing the value of the attribute, not the attribute name, to be passed to the Is Missing test.

I can see a few workarounds.

1) Set the test to Actual Values (oct-dec) = "" (instead of using Is Missing)? It's not exactly the same test, but I think it's close enough for your data.

2) Create a user parameter of type Attribute Name. Set the AttributeCreator test to $(parametername) Is Missing. Set the user parameter to point to Actual Values (oct-dec).

3) As Erik says, try the NullAttributeMapper

Either would work, but #2 is closest to what you currently have. In the meantime I'll file a problem report with the developers to get them to fix the bug, hopefully for 2016.1

Apologies for any inconvenience,

Regards

Mark

 

Userlevel 4
Badge +25

OK, I can see what is happening, there is a fault in the gui and it is causing the value of the attribute, not the attribute name, to be passed to the Is Missing test.

I can see a few workarounds.

1) Set the test to Actual Values (oct-dec) = "" (instead of using Is Missing)? It's not exactly the same test, but I think it's close enough for your data.

2) Create a user parameter of type Attribute Name. Set the AttributeCreator test to $(parametername) Is Missing. Set the user parameter to point to Actual Values (oct-dec).

3) As Erik says, try the NullAttributeMapper

Either would work, but #2 is closest to what you currently have. In the meantime I'll file a problem report with the developers to get them to fix the bug, hopefully for 2016.1

Apologies for any inconvenience,

Regards

Mark

 

fyi It's filed as PR#68329, so quote that number if you need to contact our support team about the issue

Reply