title: Seeding words into an LDA topic model in R
body: <p>I have a dataset of news articles that have been collected based on the criteria that they use the term "euroscepticism" or "eurosceptic". I have been running  topic models using the <code>lda</code> package (with <code>dfm</code> matrices built in <code>quanteda</code>) in order to identify the main topics of these articles; however, the words I am interested in do not appear in any of the topics. I want to therefore seed these words into the model, and I am not sure exactly how to do that. </p>
  
  <p>I see that the package <code>topicmodels</code> allows for an argument called seedwords, which "can be specified as a <code>matrix</code> or an object class of <code>simple_triplet_matrix</code>", but there are no other instructions. It seems that a <code>simple_triplet_matrix</code> only takes integers, and not strings - does anyone know I would then seed the words 'euroscepticism' and 'eurosceptic' into the model? </p>
  
  <p>Here is a shortened version of the code:</p>
  
  <pre><code>library("quanteda")
  library("lda")
  
  ##Load UK texts/create corpus
  UKcorp &lt;- corpus(textfile(file="~Michael/DM6/*"))
  
  ##Create document feature matrix 
  UKdfm2 &lt;- dfm(UKcorp, ngrams =1, verbose = TRUE, toLower = TRUE,
           removeNumbers = TRUE, removePunct = TRUE, removeSeparators = TRUE,
           removeTwitter = FALSE, stem = TRUE, ignoredFeatures =     
           stopwords(kind="english"), keptFeatures = NULL, language = "english",     
           thesaurus = NULL, dictionary = NULL, valuetype = "fixed"))
  
  ##Convert to lda model 
  UKlda2 &lt;- convert(UKdfm2, to = "lda")
  
  ##run model
  UKmod2 &lt;- lda.collapsed.gibbs.sampler(UKlda2$documents, K = 15, UKlda2$vocab,  
            num.iterations = 1500, alpha = .1,eta = .01, initial = NULL, burnin 
            = NULL, compute.log.likelihood = TRUE, trace = 0L, freeze.topics = FALSE)
  </code></pre>