0
$\begingroup$

The following code from the example in the Application section of http://reference.wolfram.com/language/ref/ScheduledTask.html.

CheckForFullMoon[] := 
  If[MoonPhase[Tomorrow] > 0.99, SendLunarAlertMail[]]        

This code uses a constant, 0.99, but if I want to replace the constant by a previous value (such as MoonPhase[Yesterday]). How to do that?

P.S. In fact,I want to compare the price between today and yesterday, so Wolfram Cloud should remember the price of yesterday. I have no idea how to remember the values of a previous case in the cloud.

$\endgroup$
  • $\begingroup$ You need to store the old data somewhere. A normal file would do. A more advanced option would be to use Wolfram Research's new Databin function, take a look here. $\endgroup$ – C. E. Mar 18 '15 at 13:42
  • $\begingroup$ @Pickett sounds great.it is a useful command. $\endgroup$ – partida Mar 18 '15 at 13:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.