docstr: Direct quote from Gries (2019)
  
  The version of Rosengren’s S that can handle differently large corpus parts is
  shown in (12). Each corpus part size’s in percent (in s) is multiplied with the
  frequencies of the element in question in each corpus part (in v1-n); of each product,
  one takes the square root, and those are summed up, that sum is squared, and divided
  by the overall frequency of the element in question in the corpus (f)
docstr_tok: ["Direct","quote","from","Gries","(","2019",")","The","version","of","Rosengren","\u2019","s","S","that","can","handle","differently","large","corpus","parts","is","shown","in","(","12",")",".","Each","corpus","part","size","\u2019","s","in","percent","(","in","s",")","is","multiplied","with","the","frequencies","of","the","element","in","question","in","each","corpus","part","(","in","v1-n",")",";","of","each","product",",","one","takes","the","square","root",",","and","those","are","summed","up",",","that","sum","is","squared",",","and","divided","by","the","overall","frequency","of","the","element","in","question","in","the","corpus","(","f",")"]
code: def rosengrens(self):
      """
      Direct quote from Gries (2019)
  
      The version of Rosengren’s S that can handle differently large corpus parts is
      shown in (12). Each corpus part size’s in percent (in s) is multiplied with the
      frequencies of the element in question in each corpus part (in v1-n); of each product,
      one takes the square root, and those are summed up, that sum is squared, and divided
      by the overall frequency of the element in question in the corpus (f)
      """
  
      vs = self.v.multiply(self.s)
      return (
          np.power(np.sqrt(vs).sum(axis=0).A1, 2)
          * 1.0
          / self.get_frequency()
      )
  
imports: from typing import Optional, Callable, List
  import numpy
  import pandas
  from scattertext.termranking import AbsoluteFrequencyRanker
  from scipy.sparse import csc_matrix, csr_matrix
  from sklearn.preprocessing import StandardScaler
  from scattertext.smoothing.lowess import Lowess
  from scattertext.termranking.TermRanker import TermRanker
  from scattertext.TermDocMatrix import TermDocMatrix
label_desc: Use image node_id 7 for calling the Dispersion obj's underlying member method code with example usage: obj.rosengrens() and returns: unknown