Forum Discussion
DemoFour
Continued Contributor
3 years agoError with Text.Trim
Hi people, I am trying to use a list with Text.Trim to remove punctuation and line breaks, but I am getting an error. In the Gill Raviv exersize 11-4, he uses Text.Trim and amended the code f...
DemoFour
Continued Contributor
3 years agoCan you eloborate a bit please.
The list of Punctuatuation is below. I added the .. ... !! !!! !!!! becasue of the source tweet text containing this to try and fix the issue.
The list
= {" ", "~", ",", ".", "..", ". .", "...", "....", ".....", "?", "!", "!!", "!!!", "!!!!", "!!!!!", ", ", (", "), "[", "]", "{", "}", "%", "^", "&", "*", "+", "=", ":", ";", "|", "<", ">", "/", """, """, "\", """", "#(tab)", "#(cr)", "#(lf)"}
In the Raviv book, the text is all nice and neet of course, real world data is unpredictable and not following an easy format.
I did not think this would be such an issue, to learn some M and to try out some textual clean up and analysis for an upcoming project.
HotChilli
Community Champion
3 years ago"...", "!!!!"
are multi-character strings.
"." or "!" are single character