His earliest ancestor in the early Ming period came to China in the retinue of a Tributary Emissary from the West (the Arabian Peninsula).
Because he was adept at the art of astronomy and calculating calendars, he held the office of Master Supervisor of the Imperial Observatory, and was granted a residence in Lu Fei Lane (present day South Hong Wu Street) in Nanjing.
At the age of 20, he began studying Chinese and an intensive investigation of the writings of Confucianism, Buddhism, Daoism, as well as other miscellaneous teachings.
Later, he also wrote Qingzhen Da Xue (清真大學, "The Great learning of Islam") and Xizhen Zhengda (希真正答, "Rare and True Answers").
[14] Wang Daiyu's works eventually became part of the Chinese Islamic text the Han Kitab, along with other Muslim scholars from eastern China like Liu Zhi, and Ma Zhu.