0

I have a string such like x<-"favourable 13q italic('SETA/B') mRNA low". In R, how could I get a output using parse as "favourable 13q SETA/B mRNA low"? I have tried parse(text=x) and it seems not working.

David Z
  • 6,641
  • 11
  • 50
  • 101
  • Where does this input string come from? How did it get that "fake" function call in the first place? Is `italic()` the only part of it you will ever need to parse? – MrFlick Oct 02 '18 at 15:12
  • I need the SETA/B italic in the string as a legend label in a ggplot2 figure – David Z Oct 02 '18 at 15:15
  • For use in ggplot2, see if https://stackoverflow.com/questions/32555531/how-to-italicize-part-one-or-two-words-of-an-axis-title helps. Adding an example of how your use case will help folks answer your question and/or point you to dupes. – aosmith Oct 02 '18 at 15:16
  • 2
    Possible duplicate of [How to italicize part (one or two words) of an axis title](https://stackoverflow.com/questions/32555531/how-to-italicize-part-one-or-two-words-of-an-axis-title) – pogibas Oct 02 '18 at 15:17

0 Answers0