Question: Replace parts of text: ".*" a.k.a. everything after the dot
0
gravatar for maximinio
7 months ago by
maximinio • 10
maximinio • 10 wrote:

Like in the title, I would like to replace everything after the dot using the Replace parts of the text package. Please help :)

ADD COMMENT • link • modified 7 months ago by Jennifer Hillman Jackson ♦ 25k • written 7 months ago by maximinio • 10
1
gravatar for Jennifer Hillman Jackson
7 months ago by
United States
Jennifer Hillman Jackson ♦ 25k wrote:

Hello,

If the dot is the first dot in the file, this will remove everything after it, but retains the dot.

Find pattern: \..* Replace with: .

If you want to also remove the dot, leave Replace with empty.

When using a regular expression, be sure to mark the option Find-Pattern is a regular expression as "Yes".

To test out expressions, this is a nice online tool: https://www.regextester.com/ but you can google for others. Or just test within Galaxy on a representative subset of your data, help is on the tool form.

Thanks, Jen, Galaxy team

ADD COMMENT • link written 7 months ago by Jennifer Hillman Jackson ♦ 25k
1

Flawless! Thank you

ADD REPLY • link written 7 months ago by maximinio • 10
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 179 users visited in the last hour