parameters: (self,
                                node_set_field_name,
                                node_set_ids='all',
                                value='auto')
docstring: Create a node set field on the given node sets.
  
          A default value can be passed.  If no default value is given, 0.0 will
          be used if the element field appears to be a displacement field.
          Otherwise, NaN will be used.
  
          Example:
          >>> model.create_node_set_field('temperature', 13, 298.15)
docstring_summary: Create a node set field on the given node sets.
docstring_tokens: Create a node set field on the given node sets .
function: def create_node_set_field(self,
                                node_set_field_name,
                                node_set_ids='all',
                                value='auto'):
          """
          Create a node set field on the given node sets.
  
          A default value can be passed.  If no default value is given, 0.0 will
          be used if the element field appears to be a displacement field.
          Otherwise, NaN will be used.
  
          Example:
          >>> model.create_node_set_field('temperature', 13, 298.15)
  
          """
          node_set_ids = self._format_node_set_id_list(node_set_ids)
          if value == 'auto':
              value = self._get_default_field_value(node_set_field_name)
          for node_set_id in node_set_ids:
              members = self.get_node_set_members(node_set_id)
              fields = self._get_node_set_fields(node_set_id)
              member_count = len(members)
              # if it exists, warn about overwriting
              if self.node_set_field_exists(node_set_field_name, [node_set_id]):
                  self._exists_on_entity_warning(node_set_field_name,
                                                 'node set field', node_set_id,
                                                 'node set')
              # create the new field
              new_field_values = []
              for _ in range(len(self.timesteps)):
                  new_field_values.append([value] * member_count)
              fields[node_set_field_name] = new_field_values
function_tokens: def create_node_set_field ( self , node_set_field_name , node_set_ids = 'all' , value = 'auto' ) : node_set_ids = self . _format_node_set_id_list ( node_set_ids ) if value == 'auto' : value = self . _get_default_field_value ( node_set_field_name ) for node_set_id in node_set_ids : members = self . get_node_set_members ( node_set_id ) fields = self . _get_node_set_fields ( node_set_id ) member_count = len ( members ) # if it exists, warn about overwriting if self . node_set_field_exists ( node_set_field_name , [ node_set_id ] ) : self . _exists_on_entity_warning ( node_set_field_name , 'node set field' , node_set_id , 'node set' ) # create the new field new_field_values = [ ] for _ in range ( len ( self . timesteps ) ) : new_field_values . append ( [ value ] * member_count ) fields [ node_set_field_name ] = new_field_values