Analogy is a comparison or correspondence between two things (or two groups of things) because of a third element that they are considered to share.
In logic, it is an inference or an argument from one particular to another particular, as opposed to deduction, induction, and abduction. It is also used of where at least one of the premises, or the conclusion, is general rather than particular in nature. It has the general form A is to B as C is to D.
In a broader sense, analogical reasoning is a cognitive process of transferring some information or meaning of a particular subject (the analog, or source) onto another (the target); and also the linguistic expression corresponding to such a process. The term analogy can also refer to the relation between the source and the target themselves, which is often (though not always) a similarity, as in the biological notion of analogy.
Analogy plays a significant role in human thought processes. It has been argued that analogy lies at "the core of cognition".
The English word analogy derives from the Latin analogia, itself derived from the Greek ἀναλογία, "proportion", from ana- "upon, according to" [also "against", "anew"] + logos "ratio" [also "word, speech, reckoning"]
Analogy plays a significant role in problem solving, as well as decision making, argumentation, perception, generalization, memory, creativity, invention, prediction, emotion, explanation, conceptualization and communication. It lies behind basic tasks such as the identification of places, objects and people, for example, in face perception and facial recognition systems. Hofstadter has argued that analogy is "the core of cognition".
An analogy is not a figure of speech but a kind of thought. Specific analogical language uses exemplification, comparisons, metaphors, similes, allegories, and parables, but not metonymy. Phrases like and so on, and the like, as if, and the very word like also rely on an analogical understanding by the receiver of a message including them.