Skip to content

Commit

Permalink
values
Browse files Browse the repository at this point in the history
  • Loading branch information
leliel12 committed Dec 30, 2015
1 parent 6741170 commit 41eeeac
Show file tree
Hide file tree
Showing 2 changed files with 142 additions and 5 deletions.
136 changes: 136 additions & 0 deletions notebooks/montecarlo_mc.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": [
"from skcriteria import topsis"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"mtx = [\n",
" [9, 5, 7, 5], #A1\n",
" [5, 5, 7, 9], #A2\n",
" [9, 7, 7, 5], #A3\n",
" [7, 7, 9, 7], #A4\n",
" [5, 9, 5, 7], #A5\n",
" [9, 9, 5, 7], #A6\n",
" [9, 5, 5, 9], #A7\n",
" [7, 9, 9, 7], #A8\n",
" [9, 7, 5, 7], #A9\n",
" [5, 7, 9, 7], #A10\n",
" [5, 9, 9, 5], #A11\n",
" [5, 5, 9, 9], #A12\n",
" [7, 5, 7, 9], #A13\n",
" [5, 9, 7, 7], #A14\n",
" [9, 7, 5, 9], #A15\n",
" [9, 7, 7, 9], #A16\n",
" [7, 9, 7, 9], #A17\n",
" [5, 9, 7, 5], #A18\n",
" [9, 5, 9, 5], #A19\n",
" [5, 7, 7, 9], #A20\n",
" [5, 7, 9, 5], #A21\n",
" [7, 9, 9, 5], #A22\n",
" [9, 9, 7, 5], #A23\n",
" [9, 7, 5, 5], #A24\n",
" [7, 9, 5, 9], #A25\n",
" [5, 5, 9, 7], #A26\n",
" [7, 7, 7, 9], #A27\n",
" [7, 5, 9, 5], #A28\n",
" [9, 7, 7, 7], #A29\n",
" [5, 9, 7, 9], #A30\n",
"]"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {
"collapsed": false
},
"outputs": [
{
"data": {
"text/plain": [
"[[9, 5, 7, 5],\n",
" [5, 5, 7, 9],\n",
" [9, 7, 7, 5],\n",
" [7, 7, 9, 7],\n",
" [5, 9, 5, 7],\n",
" [9, 9, 5, 7],\n",
" [9, 5, 5, 9],\n",
" [7, 9, 9, 7],\n",
" [9, 7, 5, 7],\n",
" [5, 7, 9, 7],\n",
" [5, 9, 9, 5],\n",
" [5, 5, 9, 9],\n",
" [7, 5, 7, 9],\n",
" [5, 9, 7, 7],\n",
" [9, 7, 5, 9],\n",
" [9, 7, 7, 9],\n",
" [7, 9, 7, 9],\n",
" [5, 9, 7, 5],\n",
" [9, 5, 9, 5],\n",
" [5, 7, 7, 9],\n",
" [5, 7, 9, 5],\n",
" [7, 9, 9, 5],\n",
" [9, 9, 7, 5],\n",
" [9, 7, 5, 5],\n",
" [7, 9, 5, 9],\n",
" [5, 5, 9, 7],\n",
" [7, 7, 7, 9],\n",
" [7, 5, 9, 5],\n",
" [9, 7, 7, 7],\n",
" [5, 9, 7, 9]]"
]
},
"execution_count": 4,
"metadata": {},
"output_type": "execute_result"
}
],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 2",
"language": "python",
"name": "python2"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 2
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython2",
"version": "2.7.5+"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
11 changes: 6 additions & 5 deletions notebooks/topsis_example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 2,
"metadata": {
"collapsed": true
},
Expand Down Expand Up @@ -63,16 +63,17 @@
"metadata": {},
"source": [
"Now we need the criteria:\n",
" - Is better to to give more hours of talk (maximization criteria)\n",
" - Is better to be away from the vennue (maximization)\n",
" - Is better to give a talk the last year (max)\n",
"\n",
"- Is better to to give more hours of talk (maximization criteria)\n",
"- Is better to be away from the vennue (maximization)\n",
"- Is better to give a talk the last year (max)\n",
" \n",
"So the criteria array must be like"
]
},
{
"cell_type": "code",
"execution_count": 8,
"execution_count": 4,
"metadata": {
"collapsed": true
},
Expand Down

0 comments on commit 41eeeac

Please sign in to comment.