apartment vs dwelling

apartment

noun
  • A complete domicile occupying only part of a building, especially one for rent; a flat. 

  • A conceptual space used for separation in the threading architecture. Objects in one apartment cannot directly access those in another, but must use a proxy. 

dwelling

noun
  • A house or place in which a person lives; a habitation, a home. 

How often have the words apartment and dwelling occurred in a corpus of books? (source: Google Ngram Viewer )