org-agenda-skip-function

org-agenda-skip-function is a variable defined in `org-agenda.el'.
Its value is
nil

  • This variable may be risky if used as a file-local variable.

Documentation:
Function to be called at each match during agenda construction.
If this function returns nil, the current match should not be skipped.
Otherwise, the function must return a position from where the search
should be continued.
This may also be a Lisp form, it will be evaluated.
Never set this variable using `setq' or so, because then it will apply
to all future agenda commands. If you do want a global skipping condition,
use the option `org-agenda-skip-function-global' instead.
The correct usage for `org-agenda-skip-function' is to bind it with
`let' to scope it dynamically into the agenda-constructing command.
A good way to set it is through options in `org-agenda-custom-commands'.