This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In file included from /usr/ports/local/rstudio/work/rstudio-rstudio-1c6c7bd/src/cpp/core/r_util/RSessionLaunchProfile.cpp:16: | |
In file included from /usr/ports/local/rstudio/work/rstudio-rstudio-1c6c7bd/src/cpp/core/include/core/r_util/RSessionLaunchProfile.hpp:19: | |
In file included from /usr/include/c++/v1/string:439: | |
/usr/include/c++/v1/algorithm:1720:19: error: no viable overloaded '=' | |
*__result = *__first; | |
~~~~~~~~~ ^ ~~~~~~~~ | |
/usr/include/c++/v1/algorithm:1744:19: note: in instantiation of function template specialization 'std::__1::__copy<std::__1::__bit_iterator<std::__1::vector<bool, std::__1::allocator<bool> >, true, 0>, std::__1::back_insert_iterator<std::__1::vector<json_spirit::Value_impl<json_spirit::Config_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >, std::__1::allocator<json_spirit::Value_impl<json_spirit::Config_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > > > > >' requested here |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Symbol table '.dynsym' contains 1116 entries: | |
Num: Value Size Type Bind Vis Ndx Name | |
0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND | |
1: 000000000002c858 0 SECTION LOCAL DEFAULT 9 | |
2: 0000000000000000 115 FUNC GLOBAL DEFAULT UND std::logic_error::logic_error(char const*) | |
3: 0000000000000000 476 FUNC WEAK DEFAULT UND __cxa_finalize@FBSD_1.0 (2) | |
4: 0000000000000000 163 FUNC GLOBAL DEFAULT UND std::__1::codecvt<wchar_t, char, __mbstate_t>::do_length(__mbstate_t&, char const*, char const*, unsigned long) const | |
5: 0000000000000000 24 OBJECT GLOBAL DEFAULT UND typeinfo for std::logic_error | |
6: 0000000000000000 10 FUNC GLOBAL DEFAULT UND std::logic_error::what() const | |
7: 0000000000000000 10 FUNC GLOBAL DEFAULT UND operator delete[](void*) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/usr/local/bin/g++48 -O2 -pipe -fstack-protector -Wl,-rpath=/usr/local/lib/gcc48 -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc48 -O2 -pipe -fstack-protector -Wl,-rpath=/usr/local/lib/gcc48 -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc48 -fstack-protector -Wl,-rpath=/usr/local/lib/gcc48 -L/usr/local/lib/gcc48 -Wl,-z,relro,-z,now CMakeFiles/rpostback.dir/PostbackMain.cpp.o CMakeFiles/rpostback.dir/PostbackOptions.cpp.o -o rpostback ../../core/librstudio-core.a -lboost_date_time -lboost_filesystem -lboost_iostreams -lboost_regex -lboost_signals -lboost_system -lboost_thread -lboost_chrono -lpthread -lutil /usr/local/lib/libuuid.so -lrt -lz /usr/local/lib/libinotify.so /usr/local/lib/libssl.so /usr/local/lib/libcrypto.so -lpam -Wl,-rpath,/usr/local/lib -lboost_program_options | |
CMakeFiles/rpostback.dir/PostbackOptions.cpp.o: In function `session::postback::Options::read(int, char* const*)': | |
PostbackOptions.cpp:(.text+0x105): undefined reference to `boost::program_options::options_description::op |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### prvni priklad: a++ jako VYRAZ | |
$ cat >test1.c <<EOF | |
#include<stdio.h> | |
int main() { | |
int a = 5; | |
printf("%d\n",a++); | |
return 0; | |
} | |
EOF |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Another example of specialization in Elixir. This time using | |
# a protocol. | |
# | |
# I think it's a cleaner implementation. | |
# | |
defprotocol MyProto do | |
def base_data(state) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Just an example of specialization in Elixir. | |
# | |
# I'm not sure if this pattern is a good practice in Elixir or | |
# it's too much "OOP-like" and it would be more Elixirific to | |
# use protocols. But using protocols to do the same thing would | |
# probably lead to more boilerplate code (explicitly define all | |
# funX in every protocol implementation). | |
# | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
############################################################################### | |
# Elimination of a boilerplate code using macros in Elixir. | |
# | |
# See SO question | |
# http://stackoverflow.com/questions/29573944/elixir-generating-catch-all-function-calls | |
# | |
# Run with: | |
# | |
# $ elixir catchall.exs | |
# Fun1: handled by user code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# make inverse fuction for SciPy's ECDF | |
import numpy as np | |
import statsmodels as sm | |
import scipy as sp | |
num_samples = 1000 | |
values = np.random.randn(num_samples) | |
ecdf = sm.distributions.ECDF(values) | |
ecdf_i = sp.interpolate.interp1d(ecdf.y,ecdf.x) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> someenv = new.env() | |
> someenv[["mujnazev1"]] = 1 | |
> someenv[["mujnazev2"]] = 2 | |
> ls.str(someenv) | |
mujnazev1 : num 1 | |
mujnazev2 : num 2 | |
> g = globalenv() | |
> g[["zzz"]]=5 | |
> zzz |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(xts) | |
df = read.csv("Ceny_anonym.csv",sep = ";") | |
colnames(df) = c('phone','pmax','pmin','pmid','datetime') | |
df$datetime = as.POSIXct(df$datetime,format="%d.%m.%Y %H:%M") | |
df$dtl = as.POSIXlt(df$datetime) | |
df$mno = ((df$dtl$year+1900-2008)*12)+df$dtl$mon | |
my_norm2 = function(df,name,start) { | |
idxs = which(df$phone==name) |