Skip to content

Commit bba600d

Browse files
committed
merge errors of examples
1 parent 8face6f commit bba600d

File tree

3 files changed

+0
-16
lines changed

3 files changed

+0
-16
lines changed

examples/efficientfrontier.R

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,22 +60,14 @@ efficientfrontier <- function(solver=NULL, modelDirectory=NULL) {
6060
ampl$eval("let stockopall:={};let stockrun:=stockall;")
6161
# Relax integrality
6262
ampl$setOption("relax_integrality", TRUE)
63-
<<<<<<< HEAD
6463
ampl$solve("", "gurobi")
65-
=======
66-
ampl$solve("", "")
67-
>>>>>>> master
6864
cat(sprintf("QP result = %g\n", variance$value()))
6965
# Adjust included stocks
7066
ampl$eval("let stockrun:={i in stockrun:weights[i]>0};")
7167
ampl$eval("let stockopall:={i in stockrun:weights[i]>0.5};")
7268
# Set integrality back
7369
ampl$setOption("relax_integrality", FALSE)
74-
<<<<<<< HEAD
7570
ampl$solve("", "gurobi")
76-
=======
77-
ampl$solve("", "")
78-
>>>>>>> master
7971
cat(sprintf("QMIP result = %g\n", variance$value()))
8072
# Store data of corrent frontier point
8173
returns <- c(returns, maxret - (i - 1) * stepsize)

examples/firstexample.R

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,7 @@ firstexample <- function(solver=NULL, modelDirectory=NULL) {
4747
cat(sprintf("Updated all costs.\n"))
4848

4949
# Resolve and display objective
50-
<<<<<<< HEAD
5150
ampl$solve("", "gurobi")
52-
=======
53-
ampl$solve("", "")
54-
>>>>>>> master
5551
cat(sprintf("New objective value: %f\n", totalcost$value()))
5652

5753
# Get the values of the variable Buy in a dataframe object

examples/trackingmodel.R

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,6 @@ trackingmodel <- function(solver=NULL, modelDirectory=NULL) {
6262
# Get back to the integer problem
6363
ampl$setOption("relax_integrality", FALSE)
6464
# Solve the (integer) problem
65-
<<<<<<< HEAD
6665
ampl$solve("", "gurobi")
67-
=======
68-
ampl$solve("", "")
69-
>>>>>>> master
7066
cat(sprintf("QMIP objective value %g\n", ampl$getObjectives()[[1]]$value()))
7167
}

0 commit comments

Comments
 (0)