Yes. The simplest method is to use conditional program statements that execute most of the code based on time. For example, the data could be scheduled to log at 6 a.m. and finish at 8 p.m. using CRBasic instructions such as IfTime(). Another option is to use an IfThen/EndIf construction that does a logical test of light-level measurements based on a light sensor. An additional option is to use calculated sunrise and sunset times along with a combination of RealTime() and Case instructions.
For more information, see the “Decisions, Decisions, Decisions…” article.