Last updated: 2019-08-11
workflowr checks: (Click a bullet for more information) ✔ R Markdown file: up-to-date
Great! Since the R Markdown file has been committed to the Git repository, you know the exact version of the code that produced these results.
✔ Environment: empty
Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.
✔ Seed:
set.seed(20190513)
The command set.seed(20190513)
was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.
✔ Session information: recorded
Great job! Recording the operating system, R version, and package versions is critical for reproducibility.
✔ Repository version: 75c138c
wflow_publish
or wflow_git_commit
). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:
Ignored files:
Ignored: .Rhistory
Ignored: .Rproj.user/
Ignored: data/ALL_anom.Rda
Ignored: data/ALL_clim.Rda
Ignored: data/ERA5_lhf.Rda
Ignored: data/ERA5_lwr.Rda
Ignored: data/ERA5_qnet.Rda
Ignored: data/ERA5_qnet_anom.Rda
Ignored: data/ERA5_qnet_clim.Rda
Ignored: data/ERA5_shf.Rda
Ignored: data/ERA5_swr.Rda
Ignored: data/ERA5_t2m.Rda
Ignored: data/ERA5_t2m_anom.Rda
Ignored: data/ERA5_t2m_clim.Rda
Ignored: data/ERA5_u.Rda
Ignored: data/ERA5_u_anom.Rda
Ignored: data/ERA5_u_clim.Rda
Ignored: data/ERA5_v.Rda
Ignored: data/ERA5_v_anom.Rda
Ignored: data/ERA5_v_clim.Rda
Ignored: data/GLORYS_mld.Rda
Ignored: data/GLORYS_mld_anom.Rda
Ignored: data/GLORYS_mld_clim.Rda
Ignored: data/GLORYS_u.Rda
Ignored: data/GLORYS_u_anom.Rda
Ignored: data/GLORYS_u_clim.Rda
Ignored: data/GLORYS_v.Rda
Ignored: data/GLORYS_v_anom.Rda
Ignored: data/GLORYS_v_clim.Rda
Ignored: data/NAPA_clim_U.Rda
Ignored: data/NAPA_clim_V.Rda
Ignored: data/NAPA_clim_W.Rda
Ignored: data/NAPA_clim_emp_ice.Rda
Ignored: data/NAPA_clim_emp_oce.Rda
Ignored: data/NAPA_clim_fmmflx.Rda
Ignored: data/NAPA_clim_mldkz5.Rda
Ignored: data/NAPA_clim_mldr10_1.Rda
Ignored: data/NAPA_clim_qemp_oce.Rda
Ignored: data/NAPA_clim_qla_oce.Rda
Ignored: data/NAPA_clim_qns.Rda
Ignored: data/NAPA_clim_qsb_oce.Rda
Ignored: data/NAPA_clim_qt.Rda
Ignored: data/NAPA_clim_runoffs.Rda
Ignored: data/NAPA_clim_ssh.Rda
Ignored: data/NAPA_clim_sss.Rda
Ignored: data/NAPA_clim_sst.Rda
Ignored: data/NAPA_clim_taum.Rda
Ignored: data/NAPA_clim_vars.Rda
Ignored: data/NAPA_clim_vecs.Rda
Ignored: data/OAFlux.Rda
Ignored: data/OISST_sst.Rda
Ignored: data/OISST_sst_anom.Rda
Ignored: data/OISST_sst_clim.Rda
Ignored: data/node_mean_all_anom.Rda
Ignored: data/packet_all.Rda
Ignored: data/packet_all_anom.Rda
Ignored: data/packet_nolab.Rda
Ignored: data/packet_nolab14.Rda
Ignored: data/packet_nolabgsl.Rda
Ignored: data/packet_nolabmod.Rda
Ignored: data/som_all.Rda
Ignored: data/som_all_anom.Rda
Ignored: data/som_nolab.Rda
Ignored: data/som_nolab14.Rda
Ignored: data/som_nolab_16.Rda
Ignored: data/som_nolab_9.Rda
Ignored: data/som_nolabgsl.Rda
Ignored: data/som_nolabmod.Rda
Ignored: data/synoptic_states.Rda
Ignored: data/synoptic_vec_states.Rda
Untracked files:
Untracked: docs/assets/NAPA/
Untracked: docs/assets/no_ls/
Untracked: docs/assets/no_ls_14/
Untracked: docs/assets/no_ls_3x3/
Unstaged changes:
Modified: code/workflow.R
Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.
| File | Version | Author | Date | Message |
|---|---|---|---|---|
| html | f0d2efb | robwschlegel | 2019-08-07 | Build site. |
| Rmd | ed626bf | robwschlegel | 2019-08-07 | Ran a bunch of figures and had a meeting with Eric. More changes coming to GLORYS data tomorrow before settling on one of the experimental SOMs |
| Rmd | f27c261 | robwschlegel | 2019-08-06 | Working towards pipeline optimised for testing different SOM inputs |
| Rmd | 62df032 | robwschlegel | 2019-08-02 | Some work towards the SOM analysis functions |
| html | 81e961d | robwschlegel | 2019-07-09 | Build site. |
| Rmd | 2490b95 | robwschlegel | 2019-07-08 | Getting there |
| Rmd | 82b8ef8 | robwschlegel | 2019-07-08 | Nearly finished with first pass at writing down node results. |
| Rmd | d73fbc0 | robwschlegel | 2019-07-02 | Analysed most of the outputs |
| Rmd | fd36d4c | robwschlegel | 2019-06-19 | Talk is as ready as its getting |
| Rmd | 7ff9b8b | robwschlegel | 2019-06-17 | More work on the talk |
| Rmd | 1bbfd07 | robwschlegel | 2019-06-16 | First draft of figures almost complete. |
| Rmd | dd82bc0 | robwschlegel | 2019-06-16 | Merging with offline edits |
| Rmd | c7c29ef | robwschlegel | 2019-06-16 | Uh-oh |
| Rmd | 84e9464 | robwschlegel | 2019-06-15 | Little notes |
| Rmd | 35d4717 | robwschlegel | 2019-06-13 | Added URL links to publications whose figures form the base of the figures in this project |
| Rmd | b25762e | robwschlegel | 2019-06-12 | More work on figures |
| Rmd | 413bb8b | robwschlegel | 2019-06-12 | Working on pixel interpolation |
| html | c23c50b | robwschlegel | 2019-06-10 | Build site. |
| html | 028d3cc | robwschlegel | 2019-06-10 | Build site. |
| Rmd | c6b3c7b | robwschlegel | 2019-06-10 | Re-publish entire site. |
In this bonus vignette we will go over the creation of the figures used in the publication for this research. These figures are largely adapted from the techniques seen in Oliver et al. (2018) (https://www.sciencedirect.com/science/article/pii/S0079661117303336) and Schlegel et al. (2017) (https://www.frontiersin.org/articles/10.3389/fmars.2017.00323/full).
# Install from GitHub
# .libPaths(c("~/R-packages", .libPaths()))
# devtools::install_github("fabrice-rossi/yasomi")
# Load packages and functions from the central functions script
source("code/functions.R")
# Packages used in this vignette
# library(jsonlite, lib.loc = "../R-packages/")
library(tidyverse) # Base suite of functions
library(lubridate) # For convenient date manipulation
library(data.table) # For working with massive dataframes
# library(yasomi, lib.loc = "../R-packages/") # The SOM package of choice due to PCI compliance
# Set number of cores
doMC::registerDoMC(cores = 50)
# Disable scientific notation for numeric values
# I just find it annoying
options(scipen = 999)
# Individual regions
NWA_coords <- readRDS("data/NWA_coords_cabot.Rda")
# Corners of the study area
NWA_corners <- readRDS("data/NWA_corners.Rda")
# The base map
map_base <- ggplot2::fortify(maps::map(fill = TRUE, col = "grey80", plot = FALSE)) %>%
dplyr::rename(lon = long) %>%
mutate(group = ifelse(lon > 180, group+9999, group),
lon = ifelse(lon > 180, lon-360, lon)) %>%
select(-region, -subregion)
# Bathymetry data
# NB: This was created in a previous version of the polygon-prep vignette
bathy <- readRDS("data/NWA_bathy_lowres.Rda")
The first figure we will want is that of the study area. This figure will have multiple panels so that we can show the overall average synoptic state of the variables used in the SOM. Note that this is still a rough aproximation of what the final figure will look like.
### TO DO
# Gulf Stream curved vector
# Halifax labelled point
# Text "Labrador Sea"
# Text: "Labrador Current"
# Improve bathymetry contours
# Look into the new ggfriendly method
# One panel should contain current vectors
# And the other panel should contain bathymetry contours
# Load all clims in one file
# This file was created in the code/workflow.R
ALL_clim <- readRDS("data/ALL_clim.Rda")
# Mean variable states
system.time(
var_mean_states <- ALL_clim %>%
dplyr::select(-doy) %>%
group_by(lon, lat) %>%
summarise_all(.funs = "mean") %>%
ungroup() %>%
arrange(lon, lat)
) # 2 seconds
# The previous wind correction for when that info is brought in
# winds <- mutate(arrow_size = ((abs(u*v)/ max(abs(u*v)))+0.3)/6)
# Reduce wind/ current vectors
lon_sub <- seq(min(var_mean_states$lon), max(var_mean_states$lon), by = 1)
lat_sub <- seq(min(var_mean_states$lat), max(var_mean_states$lat), by = 1)
# currents <- currents[(currents$lon %in% lon_sub & currents$lat %in% lat_sub),]
var_mean_states_sub <- var_mean_states %>%
filter(lon %in% lon_sub, lat %in% lat_sub) %>%
group_by(lon, lat) %>%
mutate(arrow_size = abs(u_clim)+abs(v_clim),
arrow_size = ifelse(is.na(arrow_size), 0, arrow_size)) %>%
ungroup() %>%
arrange(lon, lat)
# Creating dynamic arrow sizes does not work as ggplot cannot match up the vectors correctly
var_mean_states_sub$arrow_size <- 0.1
# Establish the vector scalar for the currents
current_uv_scalar <- 2
# Establish the vector scalar for the wind
wind_uv_scalar <- 0.5
# Wind feature vector coordinates
# cyc_atlantic <- data.frame(x = c(14.0, 16.1, 16.0), y = c(-36.0, -34.4, -32.1),
# xend = c(16.0, 16.1, 14.0), yend = c(-34.5, -32.2, -30.6))
# cyc_indian <- data.frame(x = c(36.0, 33.9, 34.0), y = c(-31.5, -33.1, -35.4),
# xend = c(34.0, 33.9, 36.0), yend = c(-33.0, -35.3, -36.9))
# westerlies <- data.frame(x = c(18.0, 21.1, 24.2), y = c(-38.0, -37.8, -37.8),
# xend = c(21.0, 24.1, 27.2), yend = c(-37.8, -37.8, -38.0))
# The top figure (sea)
fig_1_top <- ggplot(data = map_base, aes(x = lon, y = lat)) +
# The ocean temperature
geom_raster(data = var_mean_states, aes(fill = sst_clim)) +
# The bathymetry
# stat_contour(data = bathy[bathy$depth < -100 & bathy$depth > -300,],
# aes(x = lon, y = lat, z = depth), alpha = 0.5,
# colour = "ivory", size = 0.5, binwidth = 200, na.rm = TRUE, show.legend = FALSE) +
# The current vectors
geom_segment(data = var_mean_states_sub, aes(xend = lon + u_clim * current_uv_scalar,
yend = lat + v_clim * current_uv_scalar),
arrow = arrow(angle = 40, length = unit(var_mean_states_sub$arrow_size, "cm"), type = "open"),
linejoin = "mitre", size = 0.4) +
# The land mass
geom_polygon(aes(group = group), fill = "grey70", colour = "black", size = 0.5, show.legend = FALSE) +
# The legend for the vector length
# geom_label(aes(x = 37.0, y = -38.0, label = "1.0 m/s\n"), size = 3, label.padding = unit(0.5, "lines")) +
# geom_segment(aes(x = 36.0, y = -38.3, xend = 38.0, yend = -38.3), linejoin = "mitre",
# arrow = arrow(angle = 40, length = unit(0.2, "cm"), type = "open")) +
# Halifax point and label
# geom_point(data = SACTN_site_list, shape = 19, size = 2.8, colour = "ivory") +
# geom_text(data = SACTN_site_list[-c(3,4,7:9,18,21,23:24),], aes(label = order), size = 1.9, colour = "red") +
# Ocean label
# annotate("text", label = "ATLANTIC\nOCEAN", x = 13.10, y = -34.0, size = 4.0, angle = 0, colour = "ivory") +
# Gulf stream line and label
# geom_segment(aes(x = 17.2, y = -32.6, xend = 15.2, yend = -29.5),
# arrow = arrow(length = unit(0.3, "cm")), size = 0.5, colour = "ivory") +
# annotate("text", label = "Benguela", x = 16.0, y = -31.8, size = 3.5, angle = 298, colour = "ivory") +
# Labrador Current line and label
# geom_segment(aes(x = 33, y = -29.5, xend = 29.8, yend = -33.0),
# arrow = arrow(length = unit(0.3, "cm")), size = 0.5, colour = "ivory") +
# annotate("text", label = "Agulhas", x = 31.7, y = -31.7, size = 3.5, angle = 53, colour = "ivory") +
# Labrador Sea label
# annotate("text", label = "Agulhas\nBank", x = 22.5, y = -35.5, size = 3.0, angle = 0, colour = "ivory") +
# Improve on the x and y axis labels
# scale_x_continuous(breaks = seq(-70, -50, 10),
# labels = scales::unit_format(suffix = "°E", sep = ""),
# position = "top") +
scale_x_continuous(breaks = seq(-70, -50, 10),
labels = c("70°W", "60°W", "50°W"),
position = "top") +
scale_y_continuous(breaks = seq(35, 55, 10),
labels = scales::unit_format(suffix = "°N", sep = "")) +
labs(x = NULL, y = NULL) +
# Slightly shrink the plotting area
coord_cartesian(xlim = NWA_corners[1:2], ylim = NWA_corners[3:4], expand = F) +
# Use viridis colour scheme
scale_fill_viridis_c(name = "Temp.\n(°C)", option = "D", breaks = seq(0, 25, 5)) +
# Adjust the theme
theme_bw() +
theme(panel.border = element_rect(fill = NA, colour = "black", size = 1),
axis.text = element_text(size = 12, colour = "black"),
axis.ticks = element_line(colour = "black"))
fig_1_top
# The bottom figure (air)
fig_1_bottom <- ggplot(data = map_base, aes(x = lon, y = lat)) +
# The land mass
geom_polygon(aes(group = group), fill = "grey70", colour = "black", size = 0.5, show.legend = FALSE) +
# The net downward heatflux
geom_raster(data = var_mean_states, aes(fill = qnet_clim), alpha = 0.9) +
# The current vectors
geom_segment(data = var_mean_states_sub, aes(xend = lon + u10_clim * current_uv_scalar,
yend = lat + v10_clim * current_uv_scalar),
arrow = arrow(angle = 40, length = unit(var_mean_states_sub$arrow_size, "cm"), type = "open"),
linejoin = "mitre", size = 0.4, alpha = 0.3) +
# The legend for the vector length
# geom_label(aes(x = 37.0, y = -38.0, label = "4.0 m/s\n"), size = 3, label.padding = unit(0.5, "lines")) +
# geom_segment(aes(x = 36.0, y = -38.3, xend = 38.0, yend = -38.3), linejoin = "mitre",
# arrow = arrow(angle = 40, length = unit(0.2, "cm"), type = "open")) +
# The sub/regions
# geom_polygon(data = NWA_coords, aes(group = region, fill = region, colour = region), alpha = 0.2) +
# South Atlantic Anticyclone
# annotate("text", label = "SOUTH\nATLANTIC\nANTICYCLONE", x = 13.5, y = -33.5, size = 3.0, angle = 0, colour = "ivory") +
# geom_curve(data = cyc_atlantic, aes(x = x, y = y, xend = xend, yend = yend), curvature = 0.2, colour = "ivory",
# arrow = arrow(angle = 40, type = "open", length = unit(0.25,"cm"))) +
# South Indian Anticyclone
# annotate("text", label = "SOUTH\nINDIAN\nANTICYCLONE", x = 36.5, y = -34.0, size = 3.0, angle = 0, colour = "ivory") +
# geom_curve(data = cyc_indian, aes(x = x, y = y, xend = xend, yend = yend), curvature = 0.2, colour = "ivory",
# arrow = arrow(angle = 40, type = "open", length = unit(0.25,"cm"))) +
# Westerlies
# annotate("text", label = "WESTERLIES", x = 22.5, y = -37.0, size = 3.0, angle = 0, colour = "ivory") +
# geom_curve(data = westerlies, aes(x = x, y = y, xend = xend, yend = yend), colour = "ivory",
# arrow = arrow(angle = 40, type = "open", length = unit(0.25,"cm")), curvature = -0.01) +
# Improve on the x and y axis labels
scale_x_continuous(breaks = seq(-70, -50, 10),
labels = c("70°W", "60°W", "50°W")) +
scale_y_continuous(breaks = seq(35, 55, 10),
labels = scales::unit_format(suffix = "°N", sep = "")) +
labs(x = NULL, y = NULL) +
# Scale bar
# scaleBar(lon = 22.0, lat = -29.5, distanceLon = 200, distanceLat = 50, distanceLegend = 90, dist.unit = "km",
# arrow.length = 100, arrow.distance = 130, arrow.North.size = 3,
# legend.colour = "ivory", arrow.colour = "ivory", N.colour = "ivory") +
# Slightly shrink the plotting area
coord_cartesian(xlim = NWA_corners[1:2], ylim = NWA_corners[3:4], expand = F) +
# Use viridis colour scheme
scale_fill_viridis_c(name = "Net\ndownward\nheat flux", option = "A") +
# Adjust the theme
theme_bw() +
theme(panel.border = element_rect(fill = NA, colour = "black", size = 1),
axis.text = element_text(size = 12, colour = "black"),
axis.ticks = element_line(colour = "black"))
fig_1_bottom
# Convert the figures to grobs
fig_1_top_grob <- ggplotGrob(fig_1_top)
# fb_inset_grob <- ggplotGrob(fb_inset)
fig_1_bottom_grob <- ggplotGrob(fig_1_bottom)
# Stick them together
# NB: This is still a bit of a mess...
fig_1 <- ggplot() +
# First set the x and y axis values so we know what the ranges are
# in order to make it easier to place our facets
coord_equal(xlim = c(1, 10), ylim = c(1, 10), expand = F) +
# Then we place our facets over one another using the coordinates we created
annotation_custom(fig_1_top_grob,
xmin = 1, xmax = 9.5, ymin = 5.5, ymax = 10) +
# annotation_custom(fb_inset_grob,
# xmin = 3.5, xmax = 5.5, ymin = 7.2, ymax = 8.8) +
annotation_custom(fig_1_bottom_grob,
xmin = 1, xmax = 10, ymin = 1, ymax = 5.5)
fig_1
# save
# ggsave(plot = fig_1, filename = "graph/fig_1.pdf", height = 8, width = 8)
This figure shows all of the nodes arranged in their order displaying the average SST and U+V current vectors for each node.
# See fig_2_func() in code/functions.R for the code to make this figure
This figure shows all of the nodes arranged in their order displaying the average surface air temperature and U+V wind vectors for each node.
# See fig_3_func() in code/functions.R for the code to make this figure
This figure shows all of the nodes arranged in their order displaying the average mixed layer depth (MLD) and net downward surface heat flux for each node. Note that each pixels MLD has already been scaled to one before running the SOM and so the MLD values shown here are proportional (e.g. on a scale of 0 – 1).
# See fig_4_func() in code/functions.R for the code to make this figure
This figure provides a detailed breakdown of the seasonal and regional meta data behind the synoptic states being clustered into the node panels. This means it shows during which seasons the MHWs in each node were occurring, as well as in which region the MHWs were detected for each node. Something like this is shown effectively in Figure 7 of Oliver et al. (2018).
# See fig_5_func() in code/functions.R for the code to make this figure
The following figure shows when in time (x-axis) each MHW in each node occurred, similar to Figure 5 of Schlegel et al. (2017). It also shows what the cumulative intensity of the event is (y-axis) as well as the season of occurrence.
# See fig_6_func() in code/functions.R for the code to make this figure
This figure is the same as Figure 6 above, but instead shows what the max intensity of the event is (y-axis) as well as the region in which it occurred.
# See fig_7_func() in code/functions.R for the code to make this figure
This table will show a synopsis of what each node appears to portray. It will be primarily modelled after Table 4 of Oliver et al. (2018).
# Node 1: Warm pulse of GS near NS coast. Shallowing mixed layer, low wind stress, and strong negative heat flux. Mostly gm and ss, almost no nfs. Almost entirely summer and autumn from 2013 - 2016. Mostly smaller evets but a few are massive.
# Node 2: Cold GS with warm LC caused by positive heat flux, low wind stress, and shallow mixed layer. Mostly cbs with some gsl and no mab. Occurred in only 199 in two pulses in spring and summer (June - October). Normal intensity but short duration.
# Node 3: Calm sea state with some positive heatflux into the LC causing events. Shallower mixed layer everywhere. Mostly nfs with progressively fewer events in regions down the coast. Almost none in ls. Smaller events with a couple of large ones. All seasons from 1999 - 2014.
# Node 4: Extremely shallow mixed layer with a strong positive heatflux and low wind stress. Mostly nfs with progressively fewer events further away. Smaller events. Autumn, Winter, and Spring from 1999 - 2014.
# Node 5: Slightly shallow slightly fast push of the GS into the coast becoming slightly deeper near WHOI before coming back away from the coast and chilling out. The core of the pulse has negative heatflux but the surrounding GS has a strong positive heatflux and snall wind stress. Almost exclusively occurs in mab with only a bit everywhere else. Smallish events with a few massive ones. All seasons from 2003 - 2015.
# Node 6: Slightly warmer LS and LC with cooler GS. Minor poitive heat flux into LS and large positive heat flux into GS. Normal mixed layer with low wind stress over the LS and high over the GS. Mostly in the ls with a bit in the mab with almost none elsewhere. Occurred over 1999 - 2010 in spring and summer. Smaller events that have not been increasing over time.
# Node 7: Warm waters from LS to LC to GSL and a cold GS. Strong downward heat flux over northern waters and negative flux over GS. Shallow northern waters with low wind stress while high stress over GS. Equally high in ls and nfs. A bit in cbs but almost none elsewhere. Spring - Autumn from 2000 - 2014. 2006 was a particularly strong year. Events are overall not particularly large.
# Node 8: Warm northern waters with a cold GS. Strong positive flux over LS with weaker positive flux over GSL and negative over GS. Very shallow LS and very deep GS. Affects all northern waters but highest in gsl and ls. No events in mab and almost none in gm. Almost always Autumn and Winter from 2006 - 2013. Some more intense events later on with 2010/11 being a larger year.
# Node 9: Similar to node 5. Strong nearshore GS pulse. Strong negative flux over LS and GS but positive over the rest of the Atlantic. Very strong wind stress over LS and eastern part of Atlantic, weak over the warm heat flux area of the Atlantic. Extremely deep LS and shallow GS. Occurred over 2002 - 2016 for winter and spring, events began occurring in Autumn from 2013. Evens becoming rather intense as time progresses with some massive ones. Increasing in intensity in most regions.
# Node 10: Very unstable mostly cold GS with warm GM and SS waters. Negative heat flux into shelf waters and positive into GS. High wind stress over LS and low over shelf waters. Deep GS and GM waters but shallow over SS. Spread out over most regions with fewest events in mab and nfs. A few tiny events from 2009 - 2011 but really got going from 2012 - 2013. Spring of 2013 was small while Autumn/WInter of 2012/13 was noteworthy.
# Node 11: Energetic but normal temperature GS with warm inshore waters and slightly warm LS. Positive heat flux into GS and LS but negative into inshore waters. High wind stress above LS and a bit over central AO, but negative everywhere else. Very deep mixed layer next to coast in MAB but relatively normal everywhere else. Relatively equivalent occurrence in all regions. Occurred only from July - October, 2012. A few decent sized events. Mean max intensity is decent.
# Node 12: Warm inshore and LS waters with cold GS and AO. GS is moving fast and consistent. Negative heatflux into GS and inshore waters, slightly positive into LS and AO. High wind stress over GS and AO, negative over inshore waters and LS. Very deep mixed layer along coast in mab and very shallow along coast in ls. Mostly events occurring in gsl, but also in other northern areas. Occurred every even year from 2008 to 2014 from ~June - September. Relatively small (short) events but with decent max intensities.
It may be good to create a reference multi-panel figure for each event, as seen in Schlegel et al. (2017). But given that there are nearly 700 events being considered, this is likely too much. Perhaps showing the top 100 or some sort of meaningful reduction
# Create synoptic figure for each event
# Load SACTN data
load("~/data/SACTN/AHW/SACTN_clims.Rdata")
load("data/SACTN/SACTN_events.Rdata")
load("setupParams/SACTN_site_list.Rdata")
# The files for loading
event_idx <- data.frame(event = dir("data/SOM", full.names = TRUE),
x = length(dir("data/SOM")))
# Create a synoptic atlas figure for each MHW
system.time(plyr::ddply(event_idx, c("event"), synoptic.fig, .progress = "text")) # 539 seconds
Oliver, E. C., Lago, V., Hobday, A. J., Holbrook, N. J., Ling, S. D., and Mundy, C. N. (2018). Marine heatwaves off eastern tasmania: Trends, interannual variability, and predictability. Progress in oceanography 161, 116–130.
Schlegel, R. W., Oliver, E. C., Perkins-Kirkpatrick, S., Kruger, A., and Smit, A. J. (2017). Predominant atmospheric and oceanic patterns during coastal marine heatwaves. Frontiers in Marine Science 4, 323.
sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 16.04.5 LTS
Matrix products: default
BLAS: /usr/lib/openblas-base/libblas.so.3
LAPACK: /usr/lib/libopenblasp-r0.2.18.so
locale:
[1] LC_CTYPE=en_CA.UTF-8 LC_NUMERIC=C
[3] LC_TIME=en_CA.UTF-8 LC_COLLATE=en_CA.UTF-8
[5] LC_MONETARY=en_CA.UTF-8 LC_MESSAGES=en_CA.UTF-8
[7] LC_PAPER=en_CA.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_CA.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] bindrcpp_0.2.2 tidync_0.2.1 heatwaveR_0.4.0
[4] data.table_1.11.6 lubridate_1.7.4 forcats_0.3.0
[7] stringr_1.3.1 dplyr_0.7.6 purrr_0.2.5
[10] readr_1.1.1 tidyr_0.8.1 tibble_1.4.2
[13] ggplot2_3.0.0 tidyverse_1.2.1 jsonlite_1.6
loaded via a namespace (and not attached):
[1] Rcpp_0.12.18 lattice_0.20-35 assertthat_0.2.0
[4] rprojroot_1.3-2 digest_0.6.16 foreach_1.4.4
[7] R6_2.2.2 cellranger_1.1.0 plyr_1.8.4
[10] backports_1.1.2 evaluate_0.11 httr_1.3.1
[13] pillar_1.3.0 rlang_0.2.2 lazyeval_0.2.1
[16] readxl_1.1.0 ncmeta_0.0.4 rstudioapi_0.7
[19] whisker_0.3-2 R.utils_2.7.0 R.oo_1.22.0
[22] rmarkdown_1.10 htmlwidgets_1.3 munsell_0.5.0
[25] broom_0.5.0 compiler_3.6.1 modelr_0.1.2
[28] pkgconfig_2.0.2 htmltools_0.3.6 tidyselect_0.2.4
[31] workflowr_1.1.1 codetools_0.2-15 doMC_1.3.5
[34] viridisLite_0.3.0 crayon_1.3.4 withr_2.1.2
[37] R.methodsS3_1.7.1 grid_3.6.1 nlme_3.1-137
[40] gtable_0.2.0 git2r_0.23.0 magrittr_1.5
[43] scales_1.0.0 ncdf4_1.16.1 cli_1.0.0
[46] stringi_1.2.4 xml2_1.2.0 iterators_1.0.10
[49] tools_3.6.1 glue_1.3.0 RNetCDF_1.9-1
[52] maps_3.3.0 hms_0.4.2 parallel_3.6.1
[55] yaml_2.2.0 colorspace_1.3-2 rvest_0.3.2
[58] plotly_4.9.0 knitr_1.20 bindr_0.1.1
[61] haven_1.1.2
This reproducible R Markdown analysis was created with workflowr 1.1.1


Tickerplot 2.0
Posted on Sat 19 August 2017 in tickerplot
Background
Recently I wanted to revive one of my past projects - 'tickerplot'. 'tickerplot' was a simple (and very basic) front-end to a stock charting library, I had written back then. Being able to look at historical charts of a Stock and Index is cool, but there are many places where you can do that, so a simply re-creating the old site won't be of much of a value. Instead, it will be a good idea if one could shortlist a set of Stocks that one wants to take a closer look at based on certain criteria from historical prices, to be able to identify a viable investment opportunity. For example, I would want to answer questions like -
- How many 2X in a year opportunities were there in last 15 years?
- Which stocks are outperforming mainstream index like Nifty or a broad-based index like Nifty 500 over last quarter.
- Stocks that have 'unusual' weekly volume in the last week.
- Stocks that crossed their 50 weekly EMA from below.
An important feature goal is - A user should be able to ask questions of her choice, so we don't simply pre-compute and show the results that we think are important. One important design requirement is - answers to such questions should be available in few seconds at the most. A user won't find this particularly useful if we took minutes to answer these questions (which is not bad by the way - but not very user friendly). The idea being, once someone shortlists such stocks, based on her questions, one can take a closer look at those.
Concretely, this becomes a data aggregation, analysis problem and supporting infrastructure.
The Stack
Since I already had some code, I started simply porting that application from a rather old version of DJango for which it was written to newer one. But, soon it became apparent, most of the data I was working back then and utilities I had written don't work anymore. NSE has a habit of changing things randomly every few months. So it was time to take a fresh look at it.
So first it started as a bunch of scripts and few experiments.
First the data needs to be downloaded from available public sources. I didn't look at any of the services mainly because - back when I did it first time (a few years ago), these services were not available, or whatever was available had at-least one limitation, that you have to get from somewhere and typically from NSE site.
Since downloading data involves a bit of screen-scraping I decided to use requests and BeautifulSoup.
Often, you have to do a very basic pre-processing, so the data needs to be in some form of SQL tables (much easier). Initially, the code was littered with too man SQL statements across several files, which made maintainability significantly challenging. SQLAlchemy provides a very Pythonic way of dealing with SQL SQLAlchemy Core. In fact SQLAlchemy is known for it's ORM, but the ORM itself is built upon the Core.
Often the data is a time-series data and often we perform computations on the fly on data, so a support for time-series data and vector computations was an important feature in data-processing library. pandas, which is based on numpy is quite ideal for processing data of this volume (about 15 years of historical data of about 1500 stocks - roughly - about 1GB - using some back of the envelope calculations.).
Since, the analytics part should run asynchronously (see below). We need a work-queue where the analytics nodes will pick up work from queue and do the processing. In the past I had used celery, but instead of using celery - which has just too many dependencies, we are going to use a simple redis based queue called rq, it's simple abstraction is good enough for the job at hand. We don't have a very complicated work-flow, so a lot of celery features might be an over-kill. In fact one could simply develop this over custom SQL tables, but an abstraction of Queue is always a correct way to start.
Architecture
The Project is called 'tickerplot'. The project has the following main components in the following repositories.
- 'tickerplot' Web Application - Project in DJango speak - Repo tickerplot-site
- 'tickerplot' Python Package - This is mainly the code that will be shared by different applications inside 'tickerplot' - Repo tickerplot
- 'tickplot' - The tickerplot charting web application - Application in DJango speak - Repo tickerplot-site
- 'tickprocess' - The tickerplot analytics application - Application in DJango speak - Repo tickerplot-site
- 'tickdownload' - A collection of utilities for data acquisition, cleaning and pre-processing - Repo tickdownload
- 'tickprocess_worker' - The worker code for the analytics application - Repo tickprocess_worker
The way these applications interact is explained in the following figure -
| Tickerplot Architecture |
Note: This is a Work In Progress, so the internal implementations of the above components are going to change considerably in the coming days, but broadly the above architecture will remain in-tact.


My Transactions
Wallet Balance
Us Dollar
165.480.00 USD
Add Funds
Completed Transactions
Currency Exchange
+ 0.16
Exchanged To Bitcoin
(BTC)
Currency Exchange
- 1,000.00
Exchanged From Bitcoin
$
Currency Exchange
+ 0.16
Exchanged To Bitcoin
(BTC)
Currency Exchange
- 1,000.00
Exchanged From Bitcoin
$
Currency Exchange
+ 0.16
Exchanged To Bitcoin
(BTC)
Currency Exchange
- 1,000.00
Exchanged From Bitcoin
$
Currency Exchange
+ 0.16
Exchanged To Bitcoin
(BTC)
Currency Exchange
- 1,000.00
Exchanged From Bitcoin
$
Currency Exchange
+ 0.16
Exchanged To Bitcoin
(BTC)
Currency Exchange
- 1,000.00
Exchanged From Bitcoin
$
Settings Content
Transactions
6
Send
Exchange
Account


{% extends "trial_borrow/Page.html" %} {% load otree i18n %} {% block title %} {% endblock %} {% block content %}
{% blocktrans %}This is the end of the trial life. Your reward in the trial life is {{ points_total1 }} Eurocents. This reward from the trial round will not be paid to you, as this is just a test.{% endblocktrans %}


Toggle navigation
kollavarsham.org
Home
Calendar
Implementations
GitHub
Contact Us
Kollavarsham Calendar
[ Work in progress... Please report issues
here
. ]
Open Source libraries for
Kolla Varsham
a.k.a.
Malayalam Era
calendar.


hiREnt | Vehicle
Update Vehicle
Enter Product ID
Enter Product Name
Enter Quantity
Quantity must be more than 1
Enter Unit Price
Price must be more than $1
Enter Amount
Amount must be more than $1
Update


Bodyguard Jax:
Solt and I were very close... He died on his way home to Elmoreden. Murdered by thieves called Road Scavengers...
Makell was the idealist, he joined the rebel army... In the end, he was caught and executed. His body was hung from a tree as a reminder to others... This tree grew animated, and is now known as the Hangman Tree.
Rambert was very much like me, working as a high trader's Guard. He lost his life in battle with a Delu Lizardman.
And now you hold the Map!
Say you want other pieces


How does JS compare to HTML and CSS?
HTML, CSS and JavaScript are computer languages that help us build websites. HTML is used to define the actual content of the page, CSS is used to define design and layout of websites (i.e. what they look like) and JavaScript allows us to tell the website how to behave and interact with visitors and can also help us store information about and for visitors through features like forms.
Explain control flow and loops using an example process from everyday life
Control flow describes the order that the computer does what you tell it to do (via your code as the set of instructions).
By default the computer follows instructions line by line from top to bottom. However, certain instructions such as looping statements (for, while and do-while) often require a break up in the top down flow.
Wiping your bottom after doing a poo can be used as an everyday life process comparable to control flow and looping.
The top down control flow is:
- sit down
- do a poo
- wipe your bottom
- flush the toilet.
But wait a minute, what if your first wipe doesn't get rid of all the poo? Steps (3) and (4) present a great opportunity to insert a poo loop that would instruct you to wipe your bottom again while poo !== 0.
Explain the difference between accessing data from arrays and objects
Objects are variables that can contain multiple things (values, properties, methods). You can get to the stuff inside objects by using the name of the property or method in the following way:
- objectName.propertyName
- objectName["propertyName"]
- objectName.methodName()
Similarly arrays can store multiple things (elements) under a single label (varible). However, elements are accessed by using an automatically assigned index number (starting from 0) e.g. [0], [1], [2].
Explain what functions are and why they are useful
A function can be described as a set of instructions or a customised JavaScript command created to carry out a particular action.
Functions are awesome because they can be defined once and reused many times; this helps us to avoid being DRY and repeating ourselves again and again and again.


Object
Oriented
Programming
For
All
The concepts of OOP
Encapsulation
Encapsulation is the process of wrapping up of data (properties) and
behaviour (methods) of an object into a single unit.
Polymorphism
'Poly' means 'many' and 'morph' means 'forms'.
So polymorphism means the ability of an object to change its form.
Inheritance
Inheritance describes the parent child relationship between two classes.
A class can get some of its characteristics from a parent class.
Abstraction
Abstraction is the ability to make a class abstract. To be abstract
means to be a concept that does not have a specific or concrete
existence


Mulyper
New
Multi-layer Perceptron Training Room
Training Data
Custom column separator
Input lines
0 0 0 1 1 0 1 1
Min-Max Scaler
One-Hot Encoder
Output lines
0 1 1 0
Min-Max Scaler
One-Hot Encoder
Network & Training Parameters
Reset Network
Load Network:
Network Lengths
Learning Rate
Training Loops
Train/Test data proportion
Cost/Loss count
Log Every
Cost/Loss
CROSS_ENTROPY
MSE (Mean Squared Error)
BINARY
Train Network
Training Information
Training Error:
0.0
Test Error:
0.0
Training Loss:
0.0
Test Loss:
0.0
Iterations:
0.0
Save Network
Use your Network
Input lines
0 0 0 1 1 0 1 1
Predict
Result CSV(TSV)
By:
Eduardo Henrique Vieira dos Santos


ID: 07ec9a62-5e84-42a7-8fd1-5802d05a838d
Agency Name: Attorney General (Dept) / Crime Prevention & Justice Administration Division
Project Name: Juvenile Justice Information System - Phase 3 Implementation
Applications: Juvenile Justice information System (JJIS)
Business Value: N/A
Project Risk: N/A
Planning Start Date: N/A
Approval Status: N/A
Projected Start Date: November 11th, 2018
Cancellation Date: N/A
Projected Date of Completion: November 1st, 2020


Arrays and Hashes
October 26, 2015 | Coding
Overview
Arrays and Hashes are great tools for you to use to store and access information in an organized way. Both are ordered lists that allow you to store different types of objects (e.g. Strings, Integers, Hashes, etc.). They also allow you to access the information you stored using index integers (for arrays) and keys (for Hashes). Lets take a deeper look into both Arrays and Hashes.
Arrays
Arrays store objects, from Classes, Strings, Integers, Arrays, Hashes, etc. It is a very useful way to store and access information in an orderly manner. For example, your boss wants you to store some company data sets of monthly sales figures. You can store that information into arrays! You can also choose to store an array within an array, which makes the array class a very flexible way to store information. Here is an example of storing the numbers 1 to 10 in an array
numbers_array = [1,2,3,4,5,6,7,8,9,10]
Within this array, the values stored can be accessed in the following way:numbers_array[0] #returns 1
numbers_array[1] #returns 2
Array indexing starts at 0 for the first value stored, and has index of 1 for the second value stored, so on and so forth.
Hashes
Hashes are similar to Arrays in that it stores information in an organized way as well, but it uses key/value pairs to store and access information. Instead of having an integer indexing system (like in Arrays), Hashes uses keys to store values, and these keys are unique and can only be used once. Using keys in Hashes allows more customizability in labeling compared to Arrays, providing more detailed information about the data being stored. One example is as follows:
dog_breeds = {
:Sunny => "Golden Retriever"
:Truffles => "Chihuahua"
:Rocky => "German Shephard"
}
To access the breed for Truffles, I can do the following: dog_breeds[:Truffles] #returns "Chihuahua"
Overall, Arrays and Hashes are great ways to store information in an organized way. Choosing one over the other ultimately depends on the context in which you are working in.
Comments box


Draws debug lines on top of the screen - Note: Line does not inherit from anything except LuaClass, because it is meant to be used as a debugging tool so it should stand on its own.
More...
#include <line.h>
|
|
static Line * | Instance () |
| | Gets the Line instance.
|
| |
| static void | LuaRegisterFunctions (lua_State *L) |
| | Registers this object's functions. More...
|
| |
| static int | LuaDraw (lua_State *L) |
| | Adds two vertex points to the line instance. More...
|
| |
| static int | LuaSetShader (lua_State *L) |
| | Sets the line's shader. More...
|
| |
| static int | LuaGetShader (lua_State *L) |
| | Gets the line's shader. More...
|
| |
| template<typename T > |
| static int | LuaConstructor (lua_State *L) |
| | The LuaConstructor used by any userdata which is "new"-able. More...
|
| |
| template<typename T > |
| static int | LuaDestructor (lua_State *L) |
| | The LuaDestructor used by any userdata which is "new"-able and also needs to be garbage collected. More...
|
| |
| template<typename T > |
| static int | LuaToString (lua_State *L) |
| | The LuaToString function that is set in the metatables of generated objects. More...
|
| |
| template<typename T > |
| static int | LuaIndex (lua_State *L) |
| | The LuaIndex metamethod. More...
|
| |
| static void | LuaRegisterFunctions (lua_State *L) |
| | Registers functions of this class. More...
|
| |
Draws debug lines on top of the screen - Note: Line does not inherit from anything except LuaClass, because it is meant to be used as a debugging tool so it should stand on its own.
- Author
- Riko Ophorst
| blowbox::Line::Line |
( |
lua_State * |
L | ) |
|
Lua Line constructor.
- Parameters
-
| [in] | L | (lua_State*) the lua state |
| void blowbox::Line::Draw |
( |
ID3D11DeviceContext * |
context | ) |
|
Draws all the debugging lines.
- Parameters
-
| [in] | context | (Id3D11DeviceContext*) the context |
| int blowbox::Line::LuaDraw |
( |
lua_State * |
L | ) |
|
|
static |
Adds two vertex points to the line instance.
- Parameters
-
| [in] | L | (lua_State*) the lua state |
| int blowbox::Line::LuaGetShader |
( |
lua_State * |
L | ) |
|
|
static |
Gets the line's shader.
- Parameters
-
| [in] | L | (lua_State*) the lua state |
| void blowbox::Line::LuaRegisterFunctions |
( |
lua_State * |
L | ) |
|
|
static |
Registers this object's functions.
- Parameters
-
| [in] | L | (lua_State*) the lua state |
| int blowbox::Line::LuaSetShader |
( |
lua_State * |
L | ) |
|
|
static |
Sets the line's shader.
- Parameters
-
| [in] | L | (lua_State*) the lua state |
| void blowbox::Line::Push |
( |
Vertex |
vert | ) |
|
Pushes a vertex - Note: not const referenced, because of the way LuaDraw works.
- Parameters
-
| void blowbox::Line::SetShader |
( |
const std::string & |
path | ) |
|
Sets the shader.
- Parameters
-
| [in] | path | (const std::string&) the path to the shader |
The documentation for this class was generated from the following files:
- C:/Users/Riko pc/Documents/Visual Studio 2013/Projects/blowbox/Blowbox/elements/line.h
- C:/Users/Riko pc/Documents/Visual Studio 2013/Projects/blowbox/Blowbox/elements/line.cc


--- layout: docpage title: "Documentation" is_homepage: false is_sphinx_doc: true doc-parent: "Configuring Cassandra" doc-title: "cassandra-rackdc.properties file" doc-header-links: ' ' doc-search-path: "../search.html" extra-footer: ' ' ---
Several snitch options use the cassandra-rackdc.properties
configuration file to determine which datacenters and racks cluster nodes belong to. Information about the
network topology allows requests to be routed efficiently and to distribute replicas evenly. The following snitches can be configured here:
The GossipingPropertyFileSnitch is recommended for production. This snitch uses the datacenter and rack information configured in a local node’s cassandra-rackdc.properties
file and propagates the information to other nodes using gossip. It is the default snitch and the settings in this properties file are enabled.
The AWS EC2 snitches are configured for clusters in AWS. This snitch uses the cassandra-rackdc.properties
options to designate one of two AWS EC2 datacenter and rack naming conventions:
legacy: Datacenter name is the part of the availability zone name preceding the last “-” when the zone ends in -1 and includes the number if not -1. Rack name is the portion of the availability zone name following the last “-“.
Examples: us-west-1a => dc: us-west, rack: 1a; us-west-2b => dc: us-west-2, rack: 2b;
standard: Datacenter name is the standard AWS region name, including the number. Rack name is the region plus the availability zone letter.
Examples: us-west-1a => dc: us-west-1, rack: us-west-1a; us-west-2b => dc: us-west-2, rack: us-west-2b;
Either snitch can set to use the local or internal IP address when multiple datacenters are not communicating.


Phuse Morken
The vagrant deserter| Phuse Morken | |
|---|---|
| Age | 348 |
| Race | Morken (former Shianne) |
| Gender | Female |
| Archetype | ESFP |
| Location | Irvine Castle Town |
| Birthplace | Shiandaea |
Phuse is a long-living Morken, known for ages and subject of study for some. Spends most of her time wandering and traveling by Millward, desperately trying to soothe the boredom of her artificially extended life, constantly seeking pleasure, and some reminders that even if her body doesn't say so, she still lives.
Lore
Early-life as Shianne
Formerly knwon as Phuse Aldrienna within the Shianne community she lived in, Phuse had two siblings: Reckna and Alesi, both respectively older. Reckna worked for their parents trading their goods, their father was a huntsman and crafter, that provided some of the food and dressware of the community. Alesi helped their mother with household and assisted with the father's work. And Phuse, went off with her fater on the hunts, she wasn't very fond of long-range weapons but was very skilled with polearms and blades, which was very useful when they were caught by some fast animal.
From 20 to 40 years old, which is still a teenager for the Shiannes, Phuse spent part of her time as an entertainer at events at the community, the Shiandaea community was very festive, and mostly anything was a reason to celebration. However as time passes, the "foreign ones" as they called the expanding communities of Hanshas (the most unexceptional yet very versatile race of all, which ended up populating most of Nitera) began to approach too much the outskirts of Shianne cities. This started to redicrect their priorities and eventually they had to call hunters for military duty, during the hunts, Phuse and her father also did the job of patroling the perimiter of the village.
Family matters
Phuse and her siblings were born in a family that followed the ancient and traditional branch of the Shiannes religion, which believes that Shaardemi (evolutional variation of the Shianne species, whith bigger brains, but fragile bodies, bounding extinction and widely protected by Shiannes nowdays.) were reincarnation of Shiannes that passed away through a ritual where the oldest of the sons from a family which achieves certain social status (by electing na Elder, or receive any kind of notability endorsement from one) must volunteer to participate as they celebrate a birthday in the wanging phase of Delchroma. There are no implications if one does not volunteer, but since Shaardemi are seen as "landbound gods" and a notorious source of spiritual guidance, most of families do want to leave one of theirs to thrive as an spiritual icon.
At that time, around [[-380 year zero || placeholder date]], due to the complex and slow Shaardemi breeding process, some communities progressively were less interested in offering their sons or theirselves to the nature, for reasons ranging from the need of people to take care of the rising demmand of work at the Shianne cities to the recurrent conflicts as the Hanshas advanced into their lands to farm and explore natural resources, or even pure disbelief on the teltale stories of soul ascencion. That was the case of Phuse, but it was not the case of the massive majority of the Shiannes living at Shiandaea at that time, such thoughts were not seen with good eyes and Phuse was quite known as the rebel kid for that, rendering her entire reputation from the past worth nothing.
Phuse not only did not believe on these myths, but she also disliked the way her family raised her sister Alesi to be offered as a sacrifice when the time had come, Alesi indeed believed that this was a the best way to thank the spirits for the prosperity of their family, she was seemingly convinced by their family that that was the right thing to do. Reckna was neutral about all that, he didn't like the idea, but respected the Alesi's decision. At Alesi's 112'th birthday the ritual was set up for the end of the day, with celebration and farewells. Phuse begged to her sister to give up on that idea but she did not step back, and the ritual was carried.

On Irvine
After some days wandering through the forests and highlands, she was found by a caravan of Hansha settlers, that took her with them and accepted to have her around in exchange of her hunting skills. There she found herself in another family, much more ambitious and open-minded that the ones of her homeland.
After 20 years, she've seen what started as a camp at the end of the [?river] become a full fledged port town. Such demonstration of evolution made her wonder how such short-lived weaklings could have a much more advanced way of living than her alikes. After so many time there, she embarks on a travel to meet their capital, at the other end of the river, atop an ancient volcano, advised to hide her Shianne traits from the people from the capital, and she knew exactly why.
Phuse did not last long undercover at the capital, people were smart, mainly the townguards, that took her under arrest for believing her to be a spy. At the capital's castle, she was questioned by the Queen Louise Harpshire herself. She then explained her story and asked for asylum amongst the Hanshas. Which was partially declined as she could get yet again in trouble, so Queen Louise hosted her in the dependencies of the castle, where she would be either protected from the people, and constantly under her watch, the Queen was benevolent, but not fool. Except that the High counselor thought the opposite, and that the Queen was too naive to rule the nation during such delicate conflicts period.
Wartime
As the civil war of Irvine breaks out, Phuse is still living in the castle's complex, that was a city per se, hosting families of aristocrats, knights and merchants. The reasons for the internal conflicts were triggered by rumours of an takeover of Shiannes on their hub on the end of the river that flows down the volcano. As soon as Phuse knew about such rumours, she knew that it was about that small town she has been living for the past years.
Immediately after the spread of the rumours, information that her have been on that town just months before came into the High counselor, that was sure that Phuse was a spy. Phuse was then captured and held prisoner. Which just intensified the anger she had for their own people. That ends up being a key point in Irvine's history: the High counselor promotes a coup to take the Queen out of her role, and succeeds.
After just a few months, she eavesdrops into a conversation between guards, mentioning the use of Shiannes fallen in combat as test subjects for a weponization process that the local alchemists called "Project Morken". Phuse succeeded in communicating her interest on that project and said that would fight for them and even volunteered to be subject for testing.
Phuse then was exposed to a Silenyte-Carbon toxin and eventually suffered the effects of the experiment. Phuse Aldrienna officialy deceased on that day, months later giving birth to her new self, baptized Phuse Morken, regarding the project's name.
The Project Morken was highly experimental and vaguely known to reanimate Shianne bodies after a handful of time of exposition, and due to specific genetic configuration, only Shiannes could be used for this purpose. This transition between life and "death" confirmed her beliefs that death is true end, and that her sister had died for nothing. Further experiments in bringing other corpses into living shown that the brain damage sustained on the dead was exponentially proportional to the time elapsed between death-time and the beginning of the exposure to the substance that would bring them back.
Having that on mind, Phuse fought with all of her anger against her own kind, being the only one with the brain mostly intact, she kept her pristine hunting skills and used it in combat. Her performance in the battlefield grants her a high rank within the military, and is gifted with one of the weapons of the Forbidden Royal Archive: the Scythe of Irvine, which within the years had become her flagship, and stories about the one Lady of the Scythe spreaded quickly, eventually reaching the far away village where Phuse grew up.
As the advance of Irvinian forces goes, Phuse's unit ends up being directed to her former village, the first thing she has on her mind is to try to find her brother, to spare him and avoid him to be found first and eventually killed. As she finds him, they have a long and deep conversation, which leads Phuse to rethink her doings.
The fight on the village is a loss for both sides, since it was a village of mostly hunters, the battle was tough and both sides ended up in bad shape. Phuse returned with Reckna to the capital, and there he also volunteered for being converted into a Morken, all as part of a plot with Phuse to revert the state of war.
Within a year, Reckna finally earns trust of the usurper King, former Counselor, and gets the role of Counselor for himself, while Phuse leads one of the Irvinian Legions. They both achieve their plots and while Reckna secretly frees Queen Louise from imprisonment, Phuse gathers her men to an campaign into the very Irvine Castle, everything properly planned and made up to make the King believe it is some routine gathering.
They both succeed, and the usurper King is taken down, putting the Queen on power again, that within some years, succeeds in ceasing the reckless expansion, and the war, completely.
A few years later, Queen Louise resigns, and decides to lead a caravan to settle in the northern penninsula, near where Phuse and Reckna's village once was. So they could help with the reconstruction of the village and regaining the trust of the remaining Shiannes, that were few. Reckna decided to stay at Irvine to be sure no other war is held there, and Phuse had no choice but to stay too.
Life as a Morken
As years passed after the war, conflicts extinguish, and population and technology grows. Phuse sees, with all her longevity, generations of friends and acquaintances pass by, both Shianne and Hansha, soon she gets accustomed in having people around her come and go. And she seeks every day for brand new ways to entertain herself. Even though she lives with her brother at the Irvine Castle Town, she oftenly wanders around Millward, and when authorized, through the world.
Personality
Phuse is a very easygoing girl. Yet, too many years of life rendered her quite cold regarding others lifes, but in constant need of "warmth" from others lives. One of the things she misses the most is the lack of feelings like the adrenaline rush on her body during the hunts, feeling her heartbeat responding differently for stuff, her soul is there, but she feels and acknowledges her body is dead, artificially being held by energy generated by the disturbances of Silenyte radiation's decay, that could last hundreds of years more.
One of Phuse's most prominient traits is her intense aquired lust, she've been addicted to the sensation provided by the electromagnetic reaction of natural Carbon of living bodies with the Silenyte Carbon of her body, which causes an unutterable vibration of her cells that can be felt clearly. That is the closest of living as she can get, and also much better than what a living person can actually experience, and these are her reasons for such uncommon, and, most of the times, inadequate behaviour.
Even though she does not have a heart beating, or have chemical responses to feelings, her brain still works properly, and despites her coldness for the short lived ones, she has some sense of empathy on a macro scale, all that thanks to the influence of Reckna on her through the years.
Phuse is energetic, playful and extrovert. Usually gets in trouble for saying whatever she wants, it is not common to have her joining in fights all around, and she have been even at the jail sometimes for her misbehaviour. But she doesn't changes, and doesnt care.


Adyen API Library for ruby
Recurring is authenticated via webservice username and password.
adyen.ws_user =<EMAIL_ADDRESS>adyen.ws_passord = "super_secure_password123"
The Recurring service is used to store and manage payment method details on the Adyen server.
To store details, make a call to the store_token method:
response = adyen.recurring.store_token('{
"card": {
"number": "4111111111111111",
"expiryMonth": "8",
"expiryYear": "2018",
"cvc": "737",
"holderName": "John Smith"
},
"reference": "YOUR_REFERENCE",
"merchantAccount": "YOUR_MERCHANT_ACCOUNT",
"shopperReference": "<shopperReference>",
"recurring": {
"contract": "RECURRING,ONECLICK"
}
}')
In the response you will receive a recurringDetailReference which can later be used in conjunction with the shopperReference to create a card on file charge for the shopper:
response = adyen.payments.authorise('{
"amount":{
"value":2000,
"currency":"EUR"
},
"reference":"YOUR_REFERENCE",
"merchantAccount":"YOUR_MERCHANT_ACCOUNT",
"shopperReference":"<shopperReference>",
"selectedRecurringDetailReference":"<recurringDetailReference from store_token response>",
"recurring":{
"contract":"RECURRING"
},
"shopperInteraction":"ContAuth"
}')
To retrieve a list of payment methods associated with a shopper, use the listrecurringdetails method:
response = adyen.recurring.list_recurring_details('{
"merchantAccount": "YOUR_MERCHANT_ACCOUNT",
"shopperReference": "<shopperReference>"
}')
If you no longer wish to associate a certain payment detail with a shopper, send a call to the disable method:
response = adyen.recurring.disable('{
"merchantAccount": "YOUR_MERCHANT_ACCOUNT",
"shopperReference": "<shopperReference>",
"recurringDetailReference": "<recurringDetailReference>"
}')


| Customer Name: | Jonathan Smith |
| Email: |<EMAIL_ADDRESS>|
| State: | New York |
| Phone Number: |<PHONE_NUMBER> |
| Order #: | 12313232 |
| Order Date & Time: | Dec 27, 2013 7:16:25 PM |
| Order Status: | Closed |
| Grand Total: | $175.25 |
| Payment Information: | Credit Card |
| Item | Price | Quantity | Totals |
| BS-200 | $10.99 | 1 | $10.99 |
| BS-400 | $20.00 | 3 | $60.00 |
| BS-1000 | $600.00 | 1 | $600.00 |
| Subtotal | $670.99 | ||
| Shipping | $15 | ||
| Total | $685.99 |
| Item | Price | Quantity | Totals |
| BS-200 | $10.99 | 1 | $10.99 |
| BS-400 | $20.00 | 3 | $60.00 |
| BS-1000 | $600.00 | 1 | $600.00 |
| Subtotal | $670.99 | ||
| Shipping | $15 | ||
| Total | $685.99 |
| {{p.id}} | {{p.fn}} | {{p.dc}} | {{p.ac}} |


module Analysis: sig
.. end
Analyse a program statically with abstract interpretation
Analyse a program statically with abstract interpretation
val lastStat : Types.generic_stat_loc
Analyse a program and write results of this analysis or exceptions encountered
l
The initial location of program
program
The program already located to analyse
Returns unit
val analyseProgram : Types.loc * (Types.global_statement * Types.loc) list -> unit
Analyse a program and write results of this analysis or exceptions encountered
l
The initial location of program
program
The program already located to analyse
Returns unit


WITNESS LIST Appropriations-S/C on Health & Human Services Committee February 11, 2005-7:00A Budget For: Kidd, Carl T. (Self and Evercare of Texas) Sullivan, Sandy Lavon (Self and Evercare of Texas) Against: Anderson, Dr. Ron (Parkland Health and Hospital System) Bradberry, Anita (Texas Association for Home Care, Inc.) Brownawell, Jeff (Memorial Herman Health Care) Buck, M.D., Ernie (Primary Care Coalition and Texas Medical Association) Courtney, Geoffrey N. (Self and The ARC of Texas and McCarthy V. Hawkins Plaintiffs) Dunkelberg, Anne (Center for Public Policy Priorities) Everitt, Patti (Children's Defense Fund) Hagert, Celia (Center for Public Policy Priorities) Hawkins, John (Texas Hospital Association) Henkes, Dr. David (Bexar County Medical Society) Kafka, Bob (ADAPT of Texas) Keliher, Margaret (Dallas County) Lee, Donald (Texas Conference of Urban Counties) McDonald, M.D., Joseph D. (Border Health Caucus) O'Connor, Caroline (Texas State Employees Union) Oldham, Melanie (Self) Oneacre, Amanda (Greater Dallas Chamber) Pearson, David (Texas Organization of Rural and Community Hospitals) Rich, Sid (Texas Association of Residential Care Communities) Sonleitner, Denise (Self) Spivey, Michael (Texas Coalition of Transferring Hospitals) Svadlenak, Steve (Texas Association of Public and Non - Profit Hospitals) Tonn, Larry (Dallas Medical Resource) Vasek, Heather (Texas Association for Home Care) On: Carruth, Lisa (Health and Human Services Commission) Coleman, Pam (Health and Human Services Commission) Conner, Patty (Williamson County Crisis Center) Hawkins, Albert (Health and Human Services Commission) Henderson, Tracy (Texas Health and Human Services Commission) Johnson, Marla R. (Hays - Caldwell Woman's Center) Kane, Jerry (HHS Council) Millwee, Billy R. (Health and Human Services Commission) Murphree, Susan (Advocacy Inc.) Pressley, PhD, Laura (Self) Reasonover, Scott (Health and Human Services Commission) Suehs, Thomas (Health and Human Services Commission) Thompson, Wanda (Health and Human Services Commission) Woolbert, Lynda (Coalition for Nurses in Advanced Practice)


Home
Food
Beaches
Parks
Promenades
Fun
BEACHES
Where would you like to enjoy the sun?
Sai Kung
Stanley
Shek O
Lantau


email
mmosmond [an a with some swirlies around it] gmail [sentence ender] com
office
Room 3346, Storer Hall, UC Davis
snail mail
University of California - Davis
Department of Evolution and Ecology
Rm 2320 Storer Hall
One Shields Avenue
Davis, CA 95616 USA


The Gascon campaign of 1345, part of the Hundred Years' War, was fought between August and November in English-controlled Gascony in south-west France. Henry, Earl of Derby, commanding an Anglo-Gascon force, met a large French force at Bergerac, east of Bordeaux, and decisively defeated it. He moved to besiege the provincial capital of Périgueux, but was threatened by a much larger force commanded by John, Duke of Normandy, the son and heir of the French king. Derby withdrew and left garrisons blockading Périgueux, including one at Auberoche, which the French besieged. He returned with a small force, launched a surprise attack against the greatly superior French, and won another decisive victory, killing or capturing all of the French leaders. This campaign was the first successful English land campaign of the war; morale and prestige swung their way in the border regions of Gascony, providing an influx of taxes and army recruits, and several important regional towns went over to them. (This article is part of a featured topic: Gascon campaign of 1345.)


InfoPopper
Introduction
The developer team is constantly looking for new members. If you want to contribute, please don't hesitate to contact us or simply just join us on our IRC channel #beosimkit on irc.freenode.org
As we are all using ZETA, we hope that there are someone that can help us out with compiling a BeOS version of InfoPopper.
The InfoPopper is a system wide notification system for ZETA. Any application can send a notification to InfoPopper which then will display a message next to the Deskbar. If you have an application that you would like to add InfoPopper support to, please take a look at the Developers section.
InfoPopper is being developed by the developer team that also does the BeOS Instant Messenger kit, and the notification server started just as a small tool part of the Instant Messenger Kit. It later got taken out of the IM kit and was made in to a separate application. The first version of the InfoPopper was limited to notifications over received instant messages and status changes on your buddies. Today's InfoPopper is capable of notifying you when you receive e-mails, updates of your favourite web sites that carries RSS feeds and when you get a message in Vision or when some of your buddies the Notify List in Vision go online/offline. But also other applications have InfoPopper support.
Be aware that some of the applications that have InfoPopper support are only available for ZETA. Also, the SVG icons and the localization are only available in the ZETA version of InfoPopper. ZETA comes with an Appearence preference applications that lets you set the color to the system and some applications, one of them is of cource InfoPopper:


Up until this point in the book, we have worked with data structures that are simply that, data structures. It is often times desirable to add some "intelligence" to the data structures, such as default values, calculated values, and relationships between data.
Of the various schemes which evolved over the years, the frame based approach has been one of the more popular. Information about an object in the system is stored in a frame. The frame has multiple slots used to define the various attributes of the object. The slots can have multiple facets for holding the value for the attributes, or defaults, or procedures which are called to calculate the value.
The various frames are linked together in a hierarchy with a-kind-of (ako) links that allow for inheritance. For example, rabbits and hamsters might be stored in frames that have ako(mammal). In the frame for mammal are all of the standard attribute-values for mammals, such as skin-fur and birth-live. These are inherited by rabbits and hamsters and do not have to be specified in their frames. There can also be defaults for attributes which might be overwritten by specific species. Legs-4 applies to most mammals but monkeys would have legs-2 specified.
Another feature of a frame based system is demons. These are procedures which are activated by various updating procedures. For example a financial application might have demons on various account balances that are triggered when the value is too low. These could also have editing capabilities that made sure the data being entered is consistent with existing data. Figure 6.1 shows some samples of frames for animals.
Figure 6.1. Examples of animal frames
In order to implement a frame system in Prolog, there are two initial decisions to be made. The first is the design of the user interface, and the second is the design of the internal data structure used to hold the frame information.
The access to data in the frame system will be through three predicates.
get_frame - retrieves attribute values for a frame;
add_frame - adds or updates attribute values for a frame;
del_frame - deletes attribute values from a frame.
From the user's perspective, these operations will appear to be acting on structures that are very similar to database records. Each frame is like a record, and the slots in the frame correspond to the fields in the record. The intelligence in the frame system, such as inheritance, defaults, and demons, happens automatically for the user.
|
The first argument of each of these predicates is the name of the frame. The second argument has a list of the slots requested. Each slot is represented by a term of the form attribute - value. For example to retrieve values for the height and weight slots in the frame dennis the following query would be used: |
?- get_frame(dennis, [weight-W, height-H]).
W = 155
H = 5-10
To add a new sport for mary:
?- add_frame(mary, [sport-rugby]).
To delete a slot's value for mynorca's computer:
?- del_frame(mynorca, [computer-'PC AT']).
These three primitive frame access predicates can be used to build more complex frame applications. For example the following query would find all of the women in the frame database who are rugby players:
?- get_frame(X, [ako-woman, sport-rugby]).
X = mary ;
X = kelly;
A match-making system might have a predicate that looks for men and women who have a hobby in common:
in_common(M,
W, H) :-
get_frame(M, [ako-man, hobby-H]),
get_frame(W, [ako-woman, hobby-H]).
The next decision is to chose a type of data structure for the frames. The frame is a relatively complex structure. It has a name, and multiple slots. Each slot, which corresponds to an attribute of the frame, can have a value. This is the same as in a normal database. However in a frame system, the value is just one possible facet for the slot. There might also be default values, predicates which are used to calculate values, and demons which fire when the value in the slot is updated.
Furthermore, the frames can be organized in a hierarchy, where each frame has an a-kind-of slot which has a list of the types of frames from which this frame inherits values.
The data structure chosen for this implementation has the predicate name frame with two arguments. The first is the name of the frame, and the second is a list of slots separated by a hyphen operator from their respective facet lists. The facet list is composed of prefix operator facet names. The ones defined in the system are:
val - the simple value of the slot;
def - the default if no value is given;
calc - the predicate to call to calculate a value for the slot;
add - the predicate to call when a value is added for the slot;
del - the predicate to call when the slot's value is deleted.
Here is the format of a frame data structure:
frame(name,
[
slotname1 - [
facet1 val11,
facet2 val12,
...],
slotname2 - [
facet1 val21,
facet2 val 22,
...],
...]).
For example:
frame(man,
[
ako-[val [person]],
hair-[def short, del bald],
weight-[calc male_weight] ]).
frame(woman,
[
ako-[val [person]],
hair-[def long],
weight-[calc female_weight] ]).
In this case both man and woman have ako slots with the value of person. The hair slot has default values of long and short hair for women and men, but this would be overridden by the values in individual frames. Both have facets that point to predicates that are to be used to calculate weight, if none is given. The man's hair slot has a facet which points to a demon, bald, to be called if the value for hair is deleted.
One additional feature permits values to be either single-valued or multi-valued. Single values are represented by terms, multiple values are stored in lists. The add_frame and del_frame predicates take this into account when updating the frame. For example hair has a single value but hobbies and ako can have multiple values.
Figure 6.2. Major predicates of get_frame
The first predicate to look at is get_frame. It takes as input a query pattern, which is a list of slots and requested values. This request list (ReqList) is then compared against the SlotList associated with the frame. As each request is compared against the slot list, Prolog's unification instantiates the variables in the list. Figure 6.2 shows the major predicates used with get_frame.
get_frame(Thing,
ReqList) :-
frame(Thing, SlotList),
slot_vals(Thing, ReqList, SlotList).
The slot_vals predicate takes care of matching the request list against the slot list. It is a standard recursive list predicate, dealing with one item from the request list at a time. That item is first converted from the more free form style allowed in the input list to a more formal structure describing the request. That structure is req/4 where the arguments are:
• name of the frame;
• the requested slot;
• the requested facet;
• the requested value.
The code for slot_vals recognizes request lists, and also single slot requests not in list form. This means both of the following frame queries are legal:
?- get_frame( dennis, hair-X ).
...
?- get_frame( dennis, [hair-X, height-Y] ).
...
The slot_vals predicate is a standard list recursion predicate that fulfills each request on the list in turn. The real work is done by find_slot which fulfills the request from the frame's slot list.
slot_vals(_, [], _).
slot_vals(T,
[Req|Rest], SlotList) :-
prep_req(Req, req(T, S, F, V)),
find_slot(req(T, S, F, V), SlotList),
!, slot_vals(T, Rest, SlotList).
slot_vals(T,
Req, SlotList) :-
prep_req(Req, req(T, S, F, V)),
find_slot(req(T, S, F, V), SlotList).
The request list is composed of items of the form Slot - X. The prep_req predicate, which builds the formal query structure, must recognize three cases:
• X is a variable, in which case the value of the slot is being sought.
• X is of the form Facet(Val), in which case a particular facet is being sought.
• X is a non-variable in which case the slot value is being sought for comparison with the given value.
Here is the code which prepares the formal query structure:
prep_req(Slot-X, req(T, Slot, val, X)) :- var(X), !.
prep_req(Slot-X,
req(T, Slot, Facet, Val)) :-
nonvar(X),
X =.. [Facet, Val],
facet_list(FL),
member(Facet, FL), !.
prep_req(Slot-X, req(T, Slot, val, X)).
facet_list([val, def, calc, add, del, edit]).
For example, the query
?- get_frame(dennis, [hair-X]).
would generate the more formal request for:
req(dennis, hair, val, X)
Having now prepared a more formal request, and a slot list to fulfill it, find_slot attempts to satisfy the request. The first clause handles the case where the request is not for a variable, but really just a test to see if a certain value exists. In this case another request with a different variable (Val) is started, and the results compared with the original request. Two cases are recognized: either the value was a single value, or the value was a member of a list of values.
find_slot(req(T,
S, F, V), SlotList) :-
nonvar(V),
find_slot(req(T, S, F, Val), SlotList),
!,
(Val == V; member(V, Val)).
The next clause covers the most common case, in which the value is a variable, and the slot is a member of the slot list. Notice that the call to member both verifies that there is a structure of the form Slot-FacetList and unifies FacetList with the list of facets associated with the slot. This is because S is bound at the start of the call to member, and FacetList is not. Next, facet_val is called which gets the value from the facet list.
find_slot(req(T,
S, F, V), SlotList) :-
member(S-FacetList, SlotList),
!, facet_val(req(T, S, F, V), FacetList).
If the requested slot was not in the given slot list for the frame, then the next clause uses the values in the ako (a-kind-of) slot to see if there is a super class from which to inherit a value. The value in the ako slot might be a list, or a single value. The higher frame's slot list is then used in an attempt to satisfy the request. Note that this recurses up through the hierarchy. Note also that a frame may have multiple values in the ako slot, allowing for a more complex structure than a pure hierarchy. The system works through the list in order, trying to satisfy a request from the first ako value first.
find_slot(req(T,
S, F, V), SlotList) :-
member(ako-FacetList, SlotList),
facet_val(req(T, ako, val, Ako), FacetList),
(member(X, Ako); X = Ako),
frame(X, HigherSlots),
find_slot(req(T, S, F, V), HigherSlots), !.
The final clause in find_slot calls the error handling routine. The error handling routine should probably be set not to put up error messages in general, since many times quiet failure is what is required. During debugging it is useful to have it turned on.
find_slot(Req,
_) :-
error(['frame error looking for:', Req]).
The facet_val predicate is responsible for getting the value for the facet. It deals with four possible cases:
• The requested facet and value are on the facet list. This covers the val facet as well as specific requests for other facets.
• The requested facet is val, it is on the facet list, and its value is a list. In this case member is used to get a value.
• There is a default (def) facet which is used to get the value.
• There is a predicate to call (calc) to get the value. It expects the formal request as an argument.
If the facet has a direct value in the facet list, then there is no problem. If there is not a direct value, and the facet being asked for is the val facet, then, alternate ways of getting the value are used. First the default is tried, and if there is no default, then a calc predicate is used to compute the value. If a calc predicate is needed, then the call to it is built using the univ (=..) built-in predicate, with the request pattern as the first argument, and other arguments included in the calc predicate following.
facet_val(req(T,
S, F, V), FacetList) :-
FV =..  [Functor | Args],
CalcPred =.. [Functor, req(T, S, val, V) | Args],
call(CalcPred).
An example of a predicate used to calculate values is the female_weight predicate. It computes a default weight equal to twice the height of the individual.
female_weight(req(T,
S, F, V)) :-
get_frame(T, [height-H]),
V is H * 2.
We have now seen the code which gets values from a frame. It first sets up a list of requested slot values and then processes them one at a time. For each slot which is not defined for the frame, inheritance is used to find a parent frame that defines the slot. For the slots that are defined, each of the facets is tried in order to determine a value.
The next major predicate in the frame system adds values to slots. For single valued slots, this is a replace. For multi-valued slots, the new value is added to the list of values.
The add_frame predicate uses the same basic form as get_frame. For updates, first the old slot list is retrieved from the existing frame. Then the predicate add_slots is called with the old list (SlotList) and the update list (UList). It returns the new list (NewList).
add_frame(Thing,
UList) :-
old_slots(Thing, SlotList),
add_slots(Thing, UList, SlotList, NewList),
retract(frame(Thing, _)),
asserta(frame(Thing, NewList)), !.
The old_slots predicate usually just retrieves the slot list, however if the frame doesn't exist it creates a new frame with an empty slot list.
old_slots(Thing,
SlotList) :-
frame(Thing, SlotList), !.
old_slots(Thing,
[]) :-
asserta(frame(Thing, [])).
Next, comes add_slots which does analogous list matching to slot_vals called by get_frame.
add_slots(_, [], X, X).
add_slots(T,
[U|Rest], SlotList, NewList) :-
prep_req(U, req(T, S, F, V)),
add_slot(req(T, S, F, V), SlotList, Z),
add_slots(T, Rest, Z, NewList).
add_slots(T,
X, SlotList, NewList) :-
prep_req(X, req(T, S, F, V)),
add_slot(req(T, S, F, V), SlotList, NewList).
The add_slot predicate deletes the old slot and associated facet list from the old slot list. It then adds the new facet and value to that facet list and rebuilds the slot list. Note that delete unifies FacetList with the old facet list. FL2 is the new facet list returned from add_facet. The new slot and facet list, S-FL2 is then made the head of the add_slot output list, with SL2, the slot list after deleting the old slot as the tail.
add_slot(req(T,
S, F, V), SlotList, [S-FL2|SL2]) :-
delete(S-FacetList, SlotList, SL2),
add_facet(req(T, S, F, V), FacetList, FL2).
The add_facet predicate takes the request and deletes the old facet from the list, builds a new facet and adds it to the facet list in the same manner as add_slot.  In the case of a list, the new value is added to the list, whereas in the case of a term, the old value is replaced. The add_newval predicate does this work, taking the OldVal, the new value V and coming up with the NewVal.
add_facet(req(T,
S, F, V), FacetList, [FNew|FL2]) :-
FX =.. [F, OldVal],
delete(FX, FacetList, FL2),
add_newval(OldVal, V, NewVal),
!, check_add_demons(req(T, S, F, V), FacetList),
FNew =.. [F, NewVal].
add_newval(X, Val, Val) :- var(X), !.
add_newval(OldList,
ValList, NewList) :-
list(OldList),
list(ValList),
append(ValList, OldList, NewList), !.
add_newval([H|T], Val, [Val, H|T]).
add_newval(Val, [H|T], [Val, H|T]).
add_newval(_, Val, Val).
The intelligence in the frame comes after the cut in add_facet. If a new value has been successfully added, then check_add_demons looks for any demon procedures which must be run before the update is completed.
In check_add_demons, get_frame is called to retrieve any demon predicates in the facet add. Note that since get_frame uses inheritance, demons can be put in higher level frames that apply to all sub frames.
check_add_demons(req(T,
S, F, V), FacetList) :-
get_frame(T, S-add(Add)), !,
Add =.. [Functor | Args],
AddFunc =.. [Functor, req(T, S, F, V) | Args],
call(AddFunc).
check_add_demons(_, _).
The delete predicate used in the add routines must simply return a list that does not have the item to be deleted in it. If there was no item, then returning the same list is the right thing to do. Therefor delete looks like:
delete(X, [], []).
delete(X, [X|Y], Y) :- !.
delete(X, [Y|Z], [Y|W]) :- delete(X, Z, W).
The del_frame predicate is similar to both get_frame and add_frame. However, one major difference is in the way items are deleted from lists. When add_frame was deleting things from lists (for later replacements with updated values), the behavior of delete above was appropriate. For del_frame, a failure should occur if there is nothing to delete from the list. For this function we use remove which is similar to delete, but fails if there was nothing to delete.
remove(X, [X|Y], Y) :- !.
remove(X, [Y|Z], [Y|W]) :- remove(X, Z, W).
The rest of del_frame looks like:
del_frame(Thing)
:-
retract(frame(Thing, _)).
del_frame(Thing)
:-
error(['No frame', Thing, 'to delete']).
del_frame(Thing,
UList) :-
old_slots(Thing, SlotList),
del_slots(Thing, UList, SlotList, NewList),
retract(frame(Thing, _)),
asserta(frame(Thing, NewList)).
del_slots([], X, X, _).
del_slots(T,
[U|Rest], SlotList, NewList) :-
prep_req(U, req(T, S, F, V)),
del_slot(req(T, S, F, V), SlotList, Z),
del_slots(T, Rest, Z, NewList).
del_slots(T,
X, SlotList, NewList) :-
prep_req(X, req(T, S, F, V)),
del_slot(req(T, S, F, V), SlotList, NewList).
del_slot(req(T,
S, F, V), SlotList, [S-FL2|SL2]) :-
remove(S-FacetList, SlotList, SL2),
del_facet(req(T, S, F, V), FacetList, FL2).
del_slot(Req,
_, _) :-
error(['del_slot - unable to remove', Req]).
del_facet(req(T,
S, F, V), FacetList, FL) :-
FV =.. [F, V],
remove(FV, FacetList, FL),
!, check_del_demons(req(T, S, F, V), FacetList).
del_facet(req(T,
S, F, V), FacetList, [FNew|FL]) :-
FX =.. [F, OldVal],
remove(FX, FacetList, FL),
remove(V, OldVal, NewValList),
FNew =.. [F, NewValList],
!, check_del_demons(req(T, S, F, V), FacetList).
del_facet(Req,
_, _) :-
error(['del_facet - unable to remove', Req]).
check_del_demons(req(T,
S, F, V), FacetList) :-
get_frame(T, S-del(Del)), !,
Del =.. [Functor|Args],
DelFunc =.. [Functor, req(T, S, F, V)|Args],
call(DelFunc).
check_del_demons(_, _).
This code is essentially the same as for the add function, except the new facet values have elements deleted instead of replaced. Also, the del facet is checked for demons instead of the add facet.
Here is an example of a demon called when a man's hair is deleted. It checks with the user before proceeding.
bald(req(T,
S, F, V)) :-
write_line([T, 'will be bald, ok to proceed?']),
read(yes).
The use of inheritance makes the frame based system an intelligent way of storing data. For many expert systems, a large portion of the intelligence can be stored in frames instead of in rules. Let's consider, for example, the bird identification expert system.
In the bird system there is a hierarchy of information about birds. The rules about the order tubenose, family albatross, and particular albatrosses can all be expressed in frames as follows:
frame(tubenose,
[
level-[val order],
nostrils-[val external_tubular],
live-[val at_sea],
bill-[val hooked] ]).
frame(albatross,
[
ako-[val tubenose],
level-[val family],
size-[val large],
wings-[val long-narrow] ]).
frame(laysan_albatross,
[
ako-[val albatross],
level-[val species],
color-[val white] ]).
frame(black_footed_albatross,
[
ako-[val albatross],
level-[val species],
color-[val dark] ]).
In a forward chaining system, we would feed some facts to the system and the system would identify the bird based on those facts. We can get the same behavior with the frame system and the predicate get_frame.
For example, if we know a bird has a dark color, and long narrow wings, we can ask the query:
?- get_frame(X, [color-dark, wings-long_narrow]).
X = black_footed_albatross ;
no
Notice that this will find all of the birds that have the asked for property. The ako slots and inheritance will automatically apply the various slots from wherever in the hierarchy they appear. In the above example the color attribute was filled from the black footed albatross frame, and the wings attribute was filled from the albatross frame. This feature can be used to find all birds with long narrow wings:
?- get_frame(X, [wings-long_narrow]).
X = albatross ;
X = black_footed_albatross ;
X = laysan_albatross ;
no
The queries in this case are more general than in the various expert systems used so far. The query finds all frames that fit the given facts. The query could specify a level, but the query can also be used to bind variables for various fits. For example, to get the level in the hierarchy of the frames which have long narrow wings:
?- get_frame(X, [wings-long_narrow, level-L]).
X = albatross, L = family ;
X = black_footed_albatross, L = species;
X = laysan_albatross, L = species ;
no
For the expert systems we have seen already, we have used the Prolog database to store information. That database has been relatively simple. By writing special access predicates it is possible to create a much more sophisticated database using frame technology. These frames can then be used to store knowledge about the particular environment.
6.1 - Add other facets to the slots to allow for specification of things like explanation of the slot, certainty factors, and constraints.
6.2 - Add an automatic query-the-user facility that is called whenever a slot value is sought and there is no other frame to provide the answer. This will allow the frame system to be used as a backward chaining expert system.
Copyright ©1989,2000 Amzi! inc. All Rights Reserved.


Shipwreck
by BRIEFNEW YORK – A federal court in New York ruled that a shipwreck salvage company should be awarded silk cloth recovered from a British ship that was torpedoed and sunk by a German U-boat during World War I, but the company is not awarded 526 silver bars that were also part of the ship’s cargo.
Copyright © 2019 courthousenews.com


1. You get a NoInitialContextException.
Cause: You did not specify which implementation to use for the initial context. Specifically, the Context.INITIAL_CONTEXT_FACTORY environment property was not set to the class name of the factory that will create the initial context. Or, you did not make available to the program the classes of the service provider named by Context.INITIAL_CONTEXT_FACTORY.
Solution: Set the Context.INITIAL_CONTEXT_FACTORY environment property to the class name of the initial context implementation that you are using. See Configuration section for details.
If the property was set, then make sure that the class name was not mistyped, and that the class named is available to your program (either in its classpath or installed in the jre/lib/ext directory of the JRE). The Java Platform includes service providers for LDAP, COS naming, DNS, and the RMI registry. All other service providers must be installed and added to the execution environment.
2. You get a CommunicationException, indicating "connection refused."
Cause: The server and port identified by the Context.PROVIDER_URL environment property is not being served by the server. Perhaps someone has disabled or turned off the machine on which the server is running. Or, maybe you mistyped the server's name or port number.
Solution: Check that there is indeed a server running on that port, and restart the server if necessary. The way that you perform this check depends on the LDAP server that you are using. Usually, an administrative console or tool is available that you can use to administer the server. You may use that tool to verify the server's status.
Cause: The server does not respond to LDAP v3 connection requests. Some servers (especially public servers) do not respond correctly to the LDAP v3, ignoring the requests instead of rejecting them. Also, some LDAP v3 servers have problems handling a control that Sun's LDAP service provider automatically sends and often return a server-specific failure code.
Solution. Try setting the environment property "java.naming.ldap.version" to "2". The LDAP service provider by default attempts to connect to an LDAP server using the LDAP v3; if that fails, then it uses the LDAP v2. If the server silently ignores the v3 request, then the provider will assume that the request worked. To work around such servers, you must explicitly set the protocol version to ensure proper behavior by the server.
If the server is a v3 server, then try setting the following environment property before creating the initial context:
env.put(Context.REFERRAL, "throw");
Causes: Some servers (especially public ones) won't respond (not even with a negative answer) if you attempt to perform a search that would generate too many results or that would require the server to examine too many entries in order to generate the answer. Such servers are trying to limit the amount of resources that they expend on a per-request basis.
Or, you tried to use Secure Socket Layer (SSL) against a server/port that does not support it, and vice versa (that is, you tried to use a plain socket to talk to an SSL port).
And lastly, the server is either responding very slowly due to heavy load or is not responding at all for some reason.
Solution: If your program is hanging because the server is trying to restrict the use of its resources, then retry your request using a query that will return a single result or only a few results. This will help you to determine whether the server is alive. If it is, then you can broaden your initial query and resubmit it.
If your program is hanging because of SSL problems, then you need to find out whether the port is an SSL port and then set the Context.SECURITY_PROTOCOL environment property appropriately. If the port is an SSL port, then this property should be set to "ssl". If it is not an SSL port, then this property should not be set.
If you program is hanging for none of the above reasons the property com.sun.jndi.ldap.read.timeout comes in handy to specify the read timeout. The value of this property is the string representation of an integer representing the read timeout in milliseconds for LDAP operations. If the LDAP provider cannot get a LDAP response within that period, it aborts the read attempt. The integer should be greater than zero. An integer less than or equal to zero means no read timeout is specified which is equivalent to waiting for the response infinitely until it is received.
If this property is not specified, the default is to wait for the response until it is received.
env.put("com.sun.jndi.ldap.read.timeout", "5000"); causes the LDAP service provider to abort the read attempt if the server does not respond with a reply within 5 seconds.5. You get a NameNotFoundException.
Causes: When you initialized the initial context for the LDAP, you supply a root-distinguished name. For example, if you set the Context.PROVIDER_URL environment property for the initial context to "ldap://ldapserver:389/o=JNDITutorial" and subsequently supplied a name such as "cn=Joe,c=us", then the full name that you passed to the LDAP service was "cn=Joe,c=us,o=JNDITutorial". If this was really the name that you intended, then you should check your server to make sure that it contains such an entry.
Also, the Sun Java Directory Server return this error if you supply an incorrect distinguished name for authentication purposes. For example, the LDAP provider will throw a NameNotFoundException if you set the Context.SECURITY_PRINCIPAL environment property to "cn=Admin, o=Tutorial", and "cn=Admin, o=Tutorial" is not an entry on the LDAP server. The correct error for the Sun Java Directory Server to return actually should be something related to authentication, rather than "name not found."
Solution: Verify the name that you supplied is that of an entry existing on the server. You can do this by listing the entry's parent context or using some other tool such as the directory server's administration console.
Here are some problems that you might encounter when trying to deploy an applet that uses the JNDI classes.
Cause: Your applet was not signed, so it can connect only to the machine from which it was loaded. Or, if the applet was signed, the browser has not granted the applet permission to connect to the directory server machine.
Solution: If you want to allow the applet to connect to directory servers running on arbitrary machines, then you need to sign both your applet and all of the JNDI JARs that your applet will be using. For information on signing jars, see Signing and Verifying JAR files .
Cause: Web browsers limit access to system properties and throw a SecurityException if you attempt to read them.
Solution: If you need to obtain input for your applet, then try using applet params instead.
Cause: Firefox disables access to the java.security packages. The LDAP provider used the message digest functionality provided by java.security.MessageDigest for implementing CRAM-MD5.
Solution: Use the Java Plug-in.


Would-be terrorist fixated on ‘True Crime Community’ sentenced to prison
by Ben FeuerherdThe Ohio woman who was inspired by an online group known as the “True Crime Community” to plot the bombing of a pipeline and another terrorist attack at a local bar was sentenced to 15 years in prison on Wednesday, authorities said.
Elizabeth Lecron, 24, was also sentenced to a lifetime of supervision for plotting the attack at a Toledo bar and an interstate pipeline in Georgia in 2018, the FBI said.
Lecron, along with her boyfriend Vincent Armstrong, became obsessed with mass shootings and other violent acts through the internet fetish group, authorities alleged after her arrest.
Lecron wrote letters to Dylann Roof and the pair visited areas associated with the Columbine high school massacre, the FBI said.
They also bought guns and went to the shooting range to practice ahead of their planned attack, which they called “D-Day.”
“D-day will be my salvation,” Lecron wrote as they were practicing for the shooting.
In addition to their gun arsenal, Lecron also bought two pounds of black powder and hundreds of screws to use in the pipeline bombing in Georgia.
“Today’s sentence reflects the severity of her conduct and is a recognition of the continued efforts by law enforcement to protect the public from all violent threats,” US Attorney Justin Herdman said in a statement after the sentencing.


Hey there! I'm Tori, and I am pursuing a Computer Science Major and Japanese language Minor at Rochester Institute of Technology. I have a wide range of interests, but I'm currently focusing on language science, Japanese, and self-studying Haskell.
| School | Graduation Year | GPA | Misc. |
|---|---|---|---|
| Rochester Institute of Techonology | 2018/19 (tentative) | 3.76 (tentative) | Dean's List (1st year: 1st and 2nd semester) |
| West Babylon Senior High School | 2014 | 104.2/100.00 (weighted) | Diploma with Advanced Regents with Honors Class Rank: 7/362 |
| Organization | Title | Duties | Dates of Employment |
|---|---|---|---|
| West Babylon Public Library | Page | Shelving books/DVDs, setting up program rooms, making reminder calls, and completing check-ins for programs | August 2013 - October 2013 |
| Town of Babylon Town Hall | Citizen Services Dept. Intern | Answered constituent complaint calls for the Citizen Services Department of Town Hall and entered them into the database. Filing for the town government's health benefits department. | June 2013 - August 2013 |
For the most current info on my projects, please feel free to check out my Github page!


Advent Calendar
About
Notes
x
Coming soon!
Let
it
snow
Choose color palette
Cool title hover effect?
Tilted Angled lines?
Cool Landing Page design
Make
vector
background
Or, draw CSS Christmas shapes (presents)
Scroll
right
or pop out like PPT or
do something with scroll
fix 5px error
When click present, it slides to the center and opens, click away, slides back in place and closes
Make each
section
open a
blog post
Use
WP API
to load Posts
Create Christmas icons and
morph them
1
st
2
nd
3
rd
4
th
5
th
6
th
7
th
8
th
9
th
10
th
11
th
12
th
13
th
14
th
15
th
16
th
17
th
18
th
19
th
20
th
21
st
22
nd
23
rd
24
th
25
th


FRESH EYES by Andy Grammer
I got these fresh eyes, never seen you before like this My God, you're beautiful It's like the first time when we open the door Before we got used to usual It might seem superficial, stereotypical, man You dress up just a little and I'm like, "Oh, damn" CHORUS: So suddenly I'm in love with a stranger I can't believe that she's mine Now all I see is you with fresh eyes, fresh eyes So suddenly I'm in love with a stranger I can't believe that she's mine, yeah And now all I see is you with fresh eyes, fresh eyes Appreciation, well, it comes and it goes But I, I'll ride that wave with you It's human nature to miss what's under your nose 'Til you, 'til you remind a fool Maybe all of this is simple My heart's unconditional, yeah You dress up just a little and I'm like, "Oh, damn" CHORUS: So suddenly I'm in love with a stranger I can't believe that she's mine Now all I see is you with fresh eyes, fresh eyes So suddenly I'm in love with a stranger I can't believe that she's mine, yeah And now all I see is you with fresh eyes, fresh eyes If I could bottle this up, bottle, bottle this up, I would I would bottle this up, bottle, bottle this up, I would 'Cause you're gorgeous in this moment If I could bottle this up, I would CHORUS: So suddenly I'm in love with a stranger I can't believe that she's mine Now all I see is you with fresh eyes, fresh eyes So suddenly I'm in love with a stranger I can't believe that she's mine, yeah And now all I see is you with fresh eyes, fresh eyes Fresh Eyes Music Video - YouTube Go Back To Main Page


--- date: 2010-05-18T00:00:00Z published: true title: Expert Recommends Killing Oil-Soaked Birds = "Can I get the Pelican Crunch combo?" url: /2010/05/18/expert-recommends-killing-oil-soaked-birds-can-i-get-the-pelican-crunch-combo-/ ---
Might as well not waste them - maybe KFC or Pollo Loco can come up with a new special.


This version futher enchances XMPP support, this time I have added ability to have XMPP support from GTalk just using Google APIs without requirement to enter google password.
Features
I will update XMPP configuration article with more detailed information how to configure XMPP and use OAuth method.
execute doc/update_db/update_48.sql for update and follow standard upgrade instructions
This versions brings so mutch anticipated posibility to see notifications about new chats directly from XMPP supported apps.
Features
Changes
execute doc/update_db/update_47.sql for update
Since I implemented option to have custom language for each back office user. This option was also heritaged in widget/embed windows. This got users confusing, if I generated embed code for Russian why do I see english language? It was because the app remembered what language was set in back office. Since this small update, only site_admin will remember your language and you can easily test how widget in your language looks like without switching language in back office or using other browser.
If you desperately need this there is this github commit.
https://github.com/remdex/livehelperchat/commit/81b4a3daab46e592933aab3b3f331b780669b03c
There was a bug in install script. And during pro active chat invitation creation you could get white screen. So just execute this query:
ALTER TABLE `lh_abstract_proactive_chat_invitation`
ADD `show_random_operator` int(11) NOT NULL,
COMMENT='';
This bug in install script effected 1.63v and 1.64v.
Really sorry for this. But, bad things happens to good people :)
Features
1. Online visitors list will show page title insead of url. URL will be shown as link title.
2. Option to print and mail archived chat.
3. Option to add IP which should not be presented in online visitors list. Also this will avoid Proactive chat invitations to them. You can add then in chat configration list. "Which ip should be ignored in online users list, separate by comma"
Changes
1. Embed code generation can be reached only from configuration to avoid users misunderstandings.
execute doc/update_db/update_46.sql and follow standard upgrade instructions
Have a good weekend :)