小人さんのメモ

オンラインノートとして利用しています。

create-a-moon-phase-calendar

create-a-moon-phase-calendar

create-a-moon-phase-calendar - Google ドキュメント

 

code

2022/01
dates = DateRange["Jan 1 2022 12:00", "Jan 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["January 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/02
dates = DateRange["Feb 1 2022 12:00", "Feb 28 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["February 2022", Bold, FontFamily -> "Helvetica"], Top]


2022/03
dates = DateRange["Mar 1 2022 12:00", "Mar 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["March 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/04
dates = DateRange["Apr 1 2022 12:00", "Apr 30 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["April 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/05
dates = DateRange["May 1 2022 12:00", "May 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["May 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/06
dates = DateRange["June 1 2022 12:00", "June 30 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["June 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/07
dates = DateRange["July 1 2022 12:00", "July 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["July 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/08
dates = DateRange["Aug 1 2022 12:00", "Aug 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["August 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/09
dates = DateRange["Sept 1 2022 12:00", "Sept 30 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["September 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/10
dates = DateRange["Oct 1 2022 12:00", "Oct 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["October 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/11
dates = DateRange["Nov 1 2022 12:00", "Nov 30 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["November 2022", Bold, FontFamily -> "Helvetica"], Top]

2022/12
dates = DateRange["Dec 1 2022 12:00", "Dec 31 2022 12:00", 1];
phase = MoonPhase[dates, "Icon"]
pfr = MoonPhase[dates, "Fraction"]
moon = TimeSeriesThread[Identity, {phase, fr}];
ts = TimeSeriesMapThread[styleFun, moon]
Labeled[Grid[Partition[ts["Values"], 7, 7, 4, ""], Dividers -> False, 
  Spacings -> {0, 0}], 
 Style["December 2022", Bold, FontFamily -> "Helvetica"], Top]

 

 

※未実行。月の確認未。強制3文字の場合は要修正。