title: How to extract text that has been added to a string in R
body: <p>I have a string with a known format, something like:</p>
  
  <pre><code>"This string will have additional text here *, and it will have more here ^, and finally there will be more here ~ with some text after."
  </code></pre>
  
  <p>and a piece of data will be</p>
  
  <pre><code>"This string will have additional text here about things, and it will have more here regarding other stuff, and finally there will be more here near the end with some text after."
  </code></pre>
  
  <p>where the inserted text will not always be the same length. I need a way to identify what each of *, ^, ~ are equal to in the second string:</p>
  
  <pre><code>* = "about things"
  ^ = "regarding other stuff"
  ~ = "near the end"
  </code></pre>
  
  <p>The new string won't have the text delimited by anything but the template string will hopefully have unique enough text between each optional bit that you can identify that each time. </p>
  
  <p>I've tried looking around but cannot find anything similar to what I'm asking to even get started, any package or function would be really helpful!</p>