docstr: Length of each row in generated data equals num_nodes
docstr_tok: ["Length","of","each","row","in","generated","data","equals","num_nodes"]
code: def test_number_of_nodes(self, num_nodes):
      """Length of each row in generated data equals num_nodes"""
      graph = StructureModel()
      edges = [(n, n + 1, 1) for n in range(num_nodes - 1)]
      graph.add_weighted_edges_from(edges)
  
      data = generate_binary_data(graph, 100, seed=10)
      assert all(len(sample) == num_nodes for sample in data)
  
imports: import re
  import string
  from itertools import product
  import numpy
  import pandas
  import pytest
  from scipy import stats
  from sklearn.gaussian_process.kernels import RBF
  from causalnex.structure import StructureModel
  from causalnex.structure.data_generators import gen_stationary_dyn_net_and_df, generate_binary_data, generate_binary_dataframe, generate_categorical_dataframe, generate_continuous_data, generate_continuous_dataframe, generate_count_dataframe, generate_dataframe_dynamic, generate_structure, generate_structure_dynamic
  from tests.structure.data_generators.test_core import calculate_proba
label_desc: Use image node_id 3 for calling the TestGenerateBinaryData obj's underlying member method code with example usage: obj.test_number_of_nodes(num_nodes) without return types