You can also throw BadMethodCallException within a method when certain pre-conditions to safely call that method are not met.
For example when a method <?php $foo->analyzeData(); ?> has been called but no data as previously been loaded (from file "import" for database, wherever from).