code: def test_nanpercentile(
      *,
      dtype_and_x,
      keep_dims,
      test_flags,
      backend_fw,
      fn_name,
      on_device,
  ):
      input_dtype, x, axis, interpolation, q = dtype_and_x
      helpers.test_function(
          input_dtypes=input_dtype,
          test_flags=test_flags,
          backend_to_test=backend_fw,
          fn_name=fn_name,
          on_device=on_device,
          a=x[0],
          q=q,
          axis=axis,
          interpolation=interpolation[0],
          keepdims=keep_dims,
      )
  
imports: from hypothesis import strategies, assume
  import numpy
  import ivy
  import ivy_tests.test_ivy.helpers
  import ivy_tests.test_ivy.test_frontends.test_numpy.helpers
  from ivy_tests.test_ivy.helpers import handle_frontend_test
  from ivy_tests.test_ivy.test_functional.test_core.test_statistical import _statistical_dtype_values, _get_castable_dtype
  from ivy import inf
label_desc: Use image node_id 32 for calling a global function with example usage: test_nanpercentile() without return types