I have moved this thread to the developer portal and tagged the the question to make it easier to locate. I hope this helps find a community team member that can assist.
Not an R expert here but I noticed the sentiment function returns 4 possible elements: element_id, sentence_id, word_count, sentiment. If I understand your question correctly, you only want sentiment (the 4th element).
If that's the case, you can use this: sentiment(.arg1)$sentiment. To clarify, you'll be replacing [,4] with $sentiment.
Also, sentiment is a float, so instead of using SCRIPT_INT, you need to use SCRIPT_REAL.
I tried the function below and it seems to be working as expected:
ATTR([Current Verification Comments])))
Hope this helps!
Error "got 6800 results, expected 3400..."