I read in some religious books that it is discouraged.
Some people argue, however, that it is perfectly permissible.
If there were somethings which bring us nearer to Allah, he has certainly pointed them out. When we follow his example, we follow the most perfect man who ever lived. Moreover, he did nothing of his own accord. Everything that he told us about our faith was revealed to him by Allah. His revelations include the Qur'an and the Hadith.