code: def test_target_analysis__regression(monkeypatch):
      df_train = pd.read_csv(
          os.path.join(RESOURCE_PATH, "adult", "train_data.csv")
      ).sample(100, random_state=0)
  
      call_md_render = MagicMock()
      call_ds_render = MagicMock()
      call_cv_render = MagicMock()
      call_fiv_render = MagicMock()
      call_liv_render = MagicMock()
      with monkeypatch.context() as m:
          m.setattr(
              MarkdownSectionComponent,
              "render_markdown",
              call_md_render,
          )
          m.setattr(DatasetStatistics, "render", call_ds_render)
          m.setattr(CorrelationVisualization, "render", call_cv_render)
          m.setattr(
              FeatureInteractionVisualization, "render", call_fiv_render
          )
          m.setattr(
              LabelInsightsVisualization, "render", call_liv_render
          )
  
          state = target_analysis(
              train_data=df_train, label="fnlwgt", return_state=True
          )
  
      assert call_md_render.call_count == 3
      calls = [
          re.sub(r"[.][0-9]{4,}", ".xx", c[0][0])
          for c in call_md_render.call_args_list
      ]
      assert calls == [
          "## Target variable analysis",
          "\n".join(
              [
                  "### Distribution fits for target variable",
                  " - [kstwobign](https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.kstwobign.html)",
                  "   - p-value: 0.976",
                  "   - Parameters: (loc: -134163.xx, scale: 377621.xx)",
                  " - [gumbel_r](https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.gumbel_r.html)",
                  "   - p-value: 0.966",
                  "   - Parameters: (loc: 149399.xx, scale: 79111.xx)",
                  " - [nakagami](https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.nakagami.html)",
                  "   - p-value: 0.965",
                  "   - Parameters: (nu: 0.xx, loc: 28236.xx, scale: 192280.xx)",
                  " - [skewnorm](https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.skewnorm.html)",
                  "   - p-value: 0.963",
                  "   - Parameters: (a: 3.xx, loc: 78497.xx, scale: 150470.xx)",
                  " - [weibull_min](https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.weibull_min.html)",
                  "   - p-value: 0.963",
                  "   - Parameters: (c: 1.xx, loc: 16324.xx, scale: 200669.xx)",
              ]
          ),
          "### Target variable correlations\n - ⚠️ no fields with absolute correlation greater than `0.5` found for target variable `fnlwgt`.",
      ]
  
      call_ds_render.assert_called_once()
      call_cv_render.assert_called_once()
      call_fiv_render.assert_called_once()
      call_liv_render.assert_called_once()
      assert sorted(set(state.keys())) == [
          "correlations",
          "correlations_focus_field",
          "correlations_focus_field_threshold",
          "correlations_focus_high_corr",
          "correlations_method",
          "dataset_stats",
          "distributions_fit",
          "distributions_fit_pvalue_min",
          "interactions",
          "missing_statistics",
          "problem_type",
          "raw_type",
          "special_types",
          "variable_type",
      ]
  
      assert sorted(set(state.interactions.train_data.keys())) == [
          "__analysis__"
      ]
      assert sorted(state.correlations.train_data.columns.tolist()) == [
          "fnlwgt"
      ]
      assert (
          state.correlations_focus_high_corr.train_data.index.tolist()
          == []
      )
      assert list(state.distributions_fit.train_data.fnlwgt.keys()) == [
          "kstwobign",
          "gumbel_r",
          "nakagami",
          "skewnorm",
          "weibull_min",
      ]
  
imports: import os
  import re
  import tempfile
  from sys import platform
  from unittest.mock import ANY, MagicMock, call
  import numpy
  import pandas
  import pytest
  import autogluon.eda
  from autogluon.eda import AnalysisState
  from autogluon.eda.analysis import AnomalyDetectorAnalysis, Namespace, ShapAnalysis
  from autogluon.eda.analysis.base import BaseAnalysis
  from autogluon.eda.auto import analyze, analyze_interaction, covariate_shift_detection, dataset_overview, detect_anomalies, explain_rows, partial_dependence_plots, quick_fit, target_analysis
  from autogluon.eda.auto.simple import _is_single_numeric_variable, _prepare_pdp_data, _validate_and_normalize_pdp_args, get_default_estimator_if_not_specified, get_empty_dict_if_none
  from autogluon.eda.visualization import AnomalyScoresVisualization, ConfusionMatrix, CorrelationVisualization, DatasetStatistics, DatasetTypeMismatch, ExplainForcePlot, ExplainWaterfallPlot, FeatureImportance, FeatureInteractionVisualization, LabelInsightsVisualization, MarkdownSectionComponent, ModelLeaderboard, PropertyRendererComponent, RegressionEvaluation, XShiftSummary
  from autogluon.eda.visualization.base import AbstractVisualization
  from autogluon.eda.visualization.interaction import FeatureDistanceAnalysisVisualization, PDPInteractions
label_desc: Use image node_id 16 for calling a global function with example usage: test_target_analysis__regression(monkeypatch) without return types