SAS Data Science

Building models with SAS Enterprise Miner, SAS Factory Miner, SAS Viya (Machine Learning), SAS Visual Text Analytics, with point-and-click interfaces or programming
BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
dowdalj
Fluorite | Level 6

I'm running into problems with the REGEX feature for custom concepts in SAS contextual analysis. I'm attempting to match strings of numbers with in textual documents. For example, one of my documents contains a sentence of the form

 

"Bob and Marie live at 1234 Main St"

 

I'm attempting to use the code:

 

REGEX: \d{4}

 

To match the string "1234". When I test/run the custom concept I'm getting no matches. Does anyone know how I can fix this?

 

Cheers,

1 ACCEPTED SOLUTION

Accepted Solutions
dowdalj
Fluorite | Level 6

SOLVED: I found my own mistake.

 

I was using

 

REGEX: \d{4}

 

ins SCA. I was not aware of the systems sensitivity to spaces at the beginning. The correction I needed to make was to remove it and write

 

REGEX:\d{4}

 

View solution in original post

1 REPLY 1
dowdalj
Fluorite | Level 6

SOLVED: I found my own mistake.

 

I was using

 

REGEX: \d{4}

 

ins SCA. I was not aware of the systems sensitivity to spaces at the beginning. The correction I needed to make was to remove it and write

 

REGEX:\d{4}

 

sas-innovate-white.png

Our biggest data and AI event of the year.

Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.

Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.

 

Register now!

How to choose a machine learning algorithm

Use this tutorial as a handy guide to weigh the pros and cons of these commonly used machine learning algorithms.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 1101 views
  • 0 likes
  • 1 in conversation