Analogy is one of the pramanas, or ways through which human beings may acquire genuine and correct knowledge, according to certain schools of Indian philosophy.
You may also want to read more about Hinduism here.
Be sure to check out my writings on religion here.