code: def skipna(f: Callable) -> Callable:
      """Decorator for escaping `np.nan` and `None` in a function.
  
      Examples:
          ```python
          df[column].apply(skipna(transform))
          ```
  
          Can also be used as shown below
  
          ```python
          @skipna
          def transform(x):
              pass
          ```
  
      Args:
          f: The function to be wrapped.
  
      Returns:
          The wrapped function.
      """
  
      def _wrapped(x, *args, **kwargs):
          if (isinstance(x, float) and np.isnan(x)) or x is None:
              return np.nan
          return f(x, *args, **kwargs)
  
      return _wrapped
  
imports: from __future__ import annotations
  import importlib
  import os
  import socket
  import sys
  from functools import singledispatch, wraps
  from pathlib import Path
  from typing import Any, Callable, Dict, Iterable, List, Union
  from warnings import warn
  import numpy
  import pandas
label_desc: Use image node_id 15 for calling a global function with example usage: skipna(f) and returns: _wrapped, f, np