The Jewish Encyclopedia has interesting insights into the date that Daniel was written, including why it could not have written earlier. I'll cite one paragraph (I'm not using the quote tags because the italics makes it harder to read):
The Book of Daniel was written during the persecutions of Israel by the Syrian king Antiochus Epiphanes. This assertion is supported by the following data: The kingdom which is symbolized by the he goat (viii. 5
et seq.) is expressly named as the "kingdom of Yawan"—that is, the Grecian kingdom (viii. 21) the great horn being its first king, Alexander the Great (definitely stated in Seder "Olam R. xxx.), and the little horn Antiochus Epiphanes (175-164). This kingdom was to persecute the host of the saints "unto two thousand and three hundred evenings and mornings" (viii. 14, R. V.); that is, "half-days," or 1,150 days; and Epiphanes did, in fact, profane the sanctuary in Jerusalem for about that length of time, from Kislew 15, 168, to Kislew 25,165 (I Macc. i. 57, iv. 52). The little horn described in Dan. viii. 9-12, 23-25 has the same general characteristics as the little horn in vii. 8, 20; hence the same ruler is designated in both passages. The well-known passage ix. 23-27 also points to the same period. The first and imperative rule in interpreting it is to begin the period of the seventy times seven units (A. V. "seventy weeks") with the first period of seven (ix. 25), and to let the second period, the "sixty-two times seven units," follow this; forif this second period (the sixty-two weeks) be reckoned as beginning again from the very beginning, the third period, the "one week," must be carried back in the same way. The context demands, furthermore, that the origin of the prediction concerning the rebuilding of Jerusalem be sought in Jer. xxv. 11-13 and the parallel passage,
ib. xxix. 10. The "anointed," the "prince," mentioned after the first seven times seven units, must be Cyrus, who is called the anointed of the Lord in Isa. xlv. 1 also. He concluded the first seven weeks of years by issuing the decree of liberation, and the time that elapsed between the Chaldean destruction of Jerusalem (586) and the year 538 was just about forty-nine years. The duration of the sixty-two times seven units (434 years) does not correspond with the time 538-171 (367 years); but the chronological knowledge of that age was not very exact. The Seder 'Olam Zuṭa (ed. Meyer, p. 104) computed the Persian rule to have lasted fifty-two years. This is all the more evident as the last period of seven units must include the seven years 171-165 (see "Rev. Et. Juives," xix. 202
et seq.). This week of years began with the murder of an anointed one (compare Lev. iv. 3
et seq. on the anointing of the priest)—namely, the legitimate high priest Onias III.—and it was in the second half of this week of years that the Temple of the Lord was desecrated by an abomination—the silver altar erected by Antiochus Epiphanes in place of the Lord's altar for burnt offering (see I Macc. i. 54).
DANIEL, BOOK OF - JewishEncyclopedia.com