Skip to main content

Event Filter Editor

The Event Filter lets a study keep only the events that meet a precise condition of your own. You write the condition as a filter script in the Event Filter box, either by typing it or by inserting functions, bodies, properties, signs and operators from the box's right-click menu, which keeps the script free of typing mistakes. You then compile the script before you generate the study's events.

The Event Filter sits at the bottom of every generator study's settings. A filter is optional: an empty box applies no filter and needs no compiling.

How the Event Filter Works​

A filter script is a C# expression that is either true or false. Aquila tests every event the study finds against it: events for which the expression is true are kept, and the rest are discarded. For example, Moon.Latitude > 0 keeps only the events at which the Moon's latitude is greater than zero.

An expression is built from the items of the editor's menu: bodies such as Moon, generic bodies such as Body1 that stand for the bodies of the event, body properties such as .Latitude, zodiac signs, functions such as IsRetrograde(Body), comparison operators, and the logical operators && (And) and || (Or) that join conditions. For example, IsRetrograde(Body1) && InFireSign(Body1) keeps only the events at which the event's first body is retrograde and in a fire sign.

The filter is part of the study's configuration and is locked with the study, so the Event Filter box is disabled while the study is locked (Unlock Study). After you write or change a script, compile it (Compile Filter Script): the study can generate events only while its filter is empty or compiled. To reuse a script in other studies, save it as a preset (Filter Script Presets).

Type a Filter Script​

Write the study's filter by typing the expression. The study must be selected in the Studies list (Open an Event Generator Study) and unlocked (Unlock Study).

  1. Click in the Event Filter box.
  2. Type the filter expression.

A Mundane Aspects study with a filter script typed in the Event Filter box and the Filter script is compiled indicator still red.

The box holds the script as part of the study's configuration. Until you compile the script (Compile Filter Script), the Filter script is compiled indicator stays red and the study cannot generate events.

Insert a Script Element from the Editor Menu​

Build the script without typing mistakes by inserting a function, body, body property, zodiac sign or operator from the box's right-click menu. The study must be unlocked.

  1. Click in the Event Filter box where the text should go.
  2. Right-click the Event Filter box to open its menu.
  3. Click a submenu and the item to insert, for example Functions → IsAspecting(Body1,Body2,90,3).

The Event Filter box's right-click menu open with the Functions submenu expanded and the IsAspecting function highlighted.

Aquila inserts the item's text at the caret, or in place of any text you selected, moves the caret to the end of the inserted text and keeps the focus in the box, so you can go on typing. The Editor Menu Reference below lists every submenu and its items. A function arrives with example arguments, ready for you to edit. After you change the script, compile it again.

Editor Menu Reference​

The right-click menu of the Event Filter box replaces the box's standard text menu. It holds seven submenus, and clicking an item in any of them inserts its text into the script.

SubmenuInserts
FunctionsA function, with example arguments to edit.
Generic BodiesA name that stands for one of the bodies of the event being tested.
BodiesThe script name of a body.
Body PropertiesA property to follow a body name, such as its latitude or its speed.
Zodiac SignsThe name of a sign.
Comparison OperatorsAn operator that compares two values.
Logical OperatorsAn operator that joins two conditions.

Functions​

Each function is inserted exactly as its menu item reads, with example arguments that you then edit.

Menu ItemChecks Whether
IsAspecting(Body1,Body2,90,3)Two bodies are in an aspect within an orb: here a 90° aspect within 3°.
IsBalanced(Body1,Body2,90,3)Two bodies are balanced (at mirror-image positions on opposite sides of a balance point) within an orb.
IsParallel(Body1,Body2,1)Two bodies are parallel within an orb, on the same side of the study's reference plane.
IsContraParallel(Body1,Body2,1)Two bodies are contraparallel within an orb, on opposite sides of the study's reference plane.
InRange(Body,85,95)A body's longitude lies within a range of degrees: here 85° to 95°.
IsOutOfBounds(Body)A body's declination is out of bounds.
IsRetrograde(Body)A body is moving retrograde.
IsDirect(Body)A body is moving direct.
IsStationary(Body)A body is stationary, turning between direct and retrograde motion.
InQuadrant(Body,1)A body is in a given quadrant (1 to 4) of its sign.
InSign(Body,Aries)A body is in a given sign.
InFireSign(Body)A body is in a fire sign.
InEarthSign(Body)A body is in an earth sign.
InAirSign(Body)A body is in an air sign.
InWaterSign(Body)A body is in a water sign.
InCardinalSign(Body)A body is in a cardinal sign.
InFixedSign(Body)A body is in a fixed sign.
InMutableSign(Body)A body is in a mutable sign.
InDomicile(Body)A body is in its sign of domicile.
InDetriment(Body)A body is in its sign of detriment.
InExaltation(Body)A body is in its sign of exaltation.
InFall(Body)A body is in its sign of fall.
IsBodyPresent(Jupiter,Body1,Body2)A body is involved in the event: here Jupiter.
note

IsRetrograde, IsDirect and IsStationary describe three separate states, and exactly one of them is true for a body at any moment. A stationary body is not direct, so to keep every event at which a body is not retrograde, write IsDirect(Body) || IsStationary(Body).

Generic Bodies​

Generic bodies stand for the bodies of the event being tested, so one script works whichever bodies an event involves.

Menu ItemStands For
BodyThe event's body in a single-body study, the same as Body1.
Body1The event's first body; in a two-body study, the inner body.
Body2The event's second body; in a two-body study, the outer body.
Body3The event's third body, in a study whose events involve three bodies.

Bodies​

The Bodies submenu inserts a body's script name exactly as the item reads:

  • Sun
  • Moon
  • Mercury
  • Venus
  • Earth
  • Mars
  • Jupiter
  • Saturn
  • Uranus
  • Neptune
  • Pluto
  • NorthNode
  • MeanNode
  • LunarApogee
  • MeanApogee

Body Properties​

Each property is inserted with its leading dot, to follow a body name, as in Moon.Latitude.

Menu ItemValue
.LongitudeThe body's longitude, or its right ascension, according to the study's reference plane.
.LatitudeThe body's latitude, or its declination, according to the study's reference plane.
.DistanceThe body's distance, in AU.
.LongitudeSpeedThe body's speed in longitude or right ascension, in degrees per day.
.LatitudeSpeedThe body's speed in latitude or declination, in degrees per day.
.DistanceSpeedThe body's speed in distance, in AU per day.

Zodiac Signs​

The Zodiac Signs submenu inserts a sign's name, for functions such as InSign(Body,Aries). The signs are listed in zodiacal order:

  • Aries
  • Taurus
  • Gemini
  • Cancer
  • Leo
  • Virgo
  • Libra
  • Scorpio
  • Sagittarius
  • Capricorn
  • Aquarius
  • Pisces

Comparison Operators​

Each comparison operator is inserted as its symbol, with a space on either side:

  • Greater Than inserts >.
  • Greater Than Or Equal To inserts >=.
  • Less Than inserts <.
  • Less Than Or Equal To inserts <=.

Logical Operators​

Each logical operator is inserted as its symbol, with a space on either side:

  • And inserts &&: the expression is true only when the conditions on both sides are true.
  • Or inserts ||: the expression is true when at least one of the conditions is true.