You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+14-9Lines changed: 14 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,11 @@
1
1
# NetLogo-Extension-DBSCAN
2
2
NetLogo extension for DBSCAN clustering algorithm
3
3
4
-
It allows you to perform unsupervised density-based clustering based on specified turtle variables or proximity. The main advantage over supervised algorithms such as K-Means is that it is not necessary to specify the number of resulting clusters in advance.
4
+
It allows you to perform unsupervised density-based clustering of turtles/agents and patches based on specified variables or by proximity. The main advantage over supervised algorithms such as K-Means is that it is not necessary to specify the number of resulting clusters in advance.
5
+
6
+
This extension supports all versions of [NetLogo](https://ccl.northwestern.edu/netlogo/) from 5 onwards, including the latest version 6.1. The feature set of the extension varies depending on the NetLogo version, with full feature support from NetLogo 6 onwards.
7
+
8
+
Author: Christopher Frantz
5
9
6
10
## Usage
7
11
@@ -23,7 +27,7 @@ Example:
23
27
24
28
```
25
29
; Import extension
26
-
extensions [dbscan]
30
+
extensions [dbscan]
27
31
28
32
... instantiate agents with variable "wealth" ...
29
33
@@ -81,10 +85,10 @@ Example:
81
85
82
86
```
83
87
; Import extension
84
-
extensions [dbscan]
88
+
extensions [dbscan]
85
89
86
90
... instantiate patches with variable "resource" ...
87
-
patches-own [resource]
91
+
patches-own [resource]
88
92
89
93
... and populate variable ...
90
94
@@ -122,7 +126,7 @@ Example:
122
126
123
127
```
124
128
; Import extension
125
-
extensions [dbscan]
129
+
extensions [dbscan]
126
130
127
131
... instantiate agents with coordinates ...
128
132
@@ -135,7 +139,7 @@ The clusters can then be used as shown in the section **Clustering individuals b
135
139
136
140
For more comprehensive examples for the feature set, try out the demo that corresponds to your NetLogo version.
137
141
138
-
* For NetLogo 5, use [demo/dbscan-clustering-demo-v5.nlogo](https://github.com/chrfrantz/NetLogo-Extension-DBSCAN/blob/master/demo/dbscan-clustering-demo-v5.nlogo). (Note: the NetLogo 5 demo model does not include an example for clustering patches; this feature is only available for NetLogo 6 onwards.)
142
+
* For NetLogo 5, use [demo/dbscan-clustering-demo-v5.nlogo](https://github.com/chrfrantz/NetLogo-Extension-DBSCAN/blob/master/demo/dbscan-clustering-demo-v5.nlogo). (Note: the NetLogo 5 demo model does not include an example for clustering patches in addition to agents; this feature is only available for NetLogo 6 onwards.)
139
143
140
144
* For NetLogo 6 (and higher), use [demo/dbscan-clustering-demo-v6.nlogo](https://github.com/chrfrantz/NetLogo-Extension-DBSCAN/blob/master/demo/dbscan-clustering-demo-v6.nlogo).
141
145
@@ -147,11 +151,12 @@ For a screenshot of the entire demo GUI including control elements and further c
147
151
148
152
## Deployment
149
153
150
-
The preferred deployment variant is simply to use the auto-installation feature of NetLogo 6.1 (see Variant 0). Alternatively, you can install it using the Extension Manager provided by NetLogo 6.1 and higher (see Variant 1). For older versions of NetLogo (i.e., 6.0 or lower) you can download the corresponding jar files directly (Variant 2). Alternatively, for all supported versions of NetLogo you can build the extension from source (Variant 3).
154
+
There are various deployment approaches available, reaching from simply auto-installation to building the extension from source.
155
+
Since NetLogo 6.1 the preferred deployment variant is simply to use the auto-installation feature (see Variant 0). Alternatively, you can install the extension using the Extension Manager provided by NetLogo 6.1 and higher (see Variant 1). For older versions of NetLogo (i.e., 6.0 or lower) you can download the corresponding jar files directly (Variant 2). Alternatively, for all supported versions of NetLogo you can build the extension from source (Variant 3).
151
156
152
157
### Variant 0 (requires NetLogo 6.1.0 or higher): Auto-Installation
153
158
154
-
To trigger the installation, simply add `extensions [dbscan]` at the top of your model code and click on the `Check` button in the editor. NetLogo will then prompt you to confirm the installation of the extension and you should be able to immediately use it in your code (Note: Sometimes a restart of NetLogo seems necessary to activate newly installed extensions). You can manage the installed extension in the Extension Manager. For more details about the Extension Manager, see its official [documentation](http://ccl.northwestern.edu/netlogo/docs/extension-manager.html).
159
+
To trigger the installation, simply add `extensions [dbscan]` at the top of your model code and click on the `Check` button in the editor (or switch tabs). NetLogo will then prompt you to confirm the installation of the extension and you can immediately use the clustering features in your code (Note: Sometimes a restart of NetLogo seems necessary to activate newly installed extensions). You can manage the installed extension in the Extension Manager. For more details about the Extension Manager, see Variant 1.
155
160
156
161
### Variant 1 (requires NetLogo 6.1.0 or higher): Manual Installation via NetLogo Extension Manager
157
162
@@ -171,7 +176,7 @@ You can build the extension from scratch using maven after cloning the repositor
171
176
172
177
* For NetLogo version 6.1, run `mvn clean package -f pom-v6.1.xml`
173
178
174
-
In addition, you will need to build the [DBSCAN repository](https://github.com/chrfrantz/DBSCAN.git) (Command: `mvn package`) which contains the underlying DBSCAN algorithm. Place both jar files in the extensions subfolder `dbscan` (following the structure described under Variant 2).
179
+
In addition, you will need to build the [DBSCAN repository](https://github.com/chrfrantz/DBSCAN.git) (Command: `mvn package`) which contains the underlying DBSCAN algorithm. Place both jar files in the extensions subfolder `dbscan` (following the structure described under Variant 2). Note that all builds have been tested using Oracle's JDK 1.8.
0 commit comments