Skip to content

Commit ac004d2

Browse files
committed
updated load_example
1 parent 86befb0 commit ac004d2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

larray_editor/editor.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -648,12 +648,12 @@ def save_as(self):
648648

649649
def load_example(self):
650650
if self._ask_to_save_if_unsaved_modifications():
651-
from larray import EXAMPLE_FILES_DIR
652-
dataset_names = ("demography",)
651+
from larray.example import AVAILABLE_EXAMPLE_DATA
652+
dataset_names = AVAILABLE_EXAMPLE_DATA.keys()
653653
dataset_name, ok = QInputDialog.getItem(self, "load dataset example", "list of datasets examples",
654654
dataset_names, 0, False)
655655
if ok and dataset_name:
656-
filepath = os.path.join(EXAMPLE_FILES_DIR, 'data.h5')
656+
filepath = AVAILABLE_EXAMPLE_DATA[dataset_name]
657657
self._open_file(filepath)
658658

659659
def open_documentation(self):

0 commit comments

Comments
 (0)