class_docstr: Creates a topic model from a set of key terms based on sentence level co-occurrence.
class_docstr_tok: ["Creates","a","topic","model","from","a","set","of","key","terms","based","on","sentence","level","co-occurrence","."]
docstr: Parameters
  ----------
  terms : list or None
          If terms is list, make these the seed terms for the topoics
          If none, use the first 30 terms in get_scaled_f_scores_vs_background
  num_terms_per_topic : int, default 10
          Use this many terms per topic
  scorer : TermScorer
          Implements get_scores, default is RankDifferce, which tends to work best
  
  Returns
  -------
  dict: {term: [term1, ...], ...}
docstr_tok: ["Parameters","--","--","--","--","--","terms",":","list","or","None","If","terms","is","list",",","make","these","the","seed","terms","for","the","topoics","If","none",",","use","the","first","30","terms","in","get_scaled_f_scores_vs_background","num_terms_per_topic",":","int",",","default","10","Use","this","many","terms","per","topic","scorer",":","TermScorer","Implements","get_scores",",","default","is","RankDifferce",",","which","tends","to","work","best","Returns","--","--","--","-","dict",":","{","term",":","[","term1",",","...","]",",","...","}"]
code: def get_topics_from_terms(
      self, terms=None, num_terms_per_topic=10, scorer=RankDifference()
  ):
      """
      Parameters
      ----------
      terms : list or None
              If terms is list, make these the seed terms for the topoics
              If none, use the first 30 terms in get_scaled_f_scores_vs_background
      num_terms_per_topic : int, default 10
              Use this many terms per topic
      scorer : TermScorer
              Implements get_scores, default is RankDifferce, which tends to work best
  
      Returns
      -------
      dict: {term: [term1, ...], ...}
      """
      topic_model = {}
  
      if terms is None:
          terms = self.corpus.get_scaled_f_scores_vs_background().index[
              :30
          ]
  
      for term in terms:
          termidx = self.termidxstore.getidxstrict(term)
          labels = self.sentX[:, termidx].astype(bool).todense().A1
          poscnts = self.sentX[labels, :].astype(bool).sum(axis=0).A1
          negcnts = self.sentX[~labels, :].astype(bool).sum(axis=0).A1
          scores = scorer.get_scores(poscnts, negcnts)
          topic_model[term] = [
              self.termidxstore.getval(i)
              for i in np.argsort(-scores)[:num_terms_per_topic]
          ]
      return topic_model
  
file_path: scattertext/scattertext/topicmodel/SentencesForTopicModeling.py
imports: import numpy
  import pandas
  from sklearn.decomposition import NMF
  from sklearn.feature_extraction.text import TfidfTransformer
  from sklearn.pipeline import Pipeline
  from scattertext.CSRMatrixTools import CSRMatrixFactory
  from scattertext.ParsedCorpus import ParsedCorpus
  from scattertext.termscoring.RankDifference import RankDifference
label_desc: Use image node_id 6 for calling the SentencesForTopicModeling obj's underlying member method code with example usage: obj.get_topics_from_terms(terms, num_terms_per_topic, scorer) and returns: topic_model