|
POST
|
Thank you Nianwei - I incorporated the changes, works like a charm. attribubeField is displayed where the UNR is utilitizing a string, and not where the UNR is utilizing a function. Thank you for your all of your work on this widget over the years - it is quite an elegant solution. Robert Robert Scheitlin, GISP, thanks to you as well-- David
... View more
09-24-2014
11:17 AM
|
0
|
0
|
2376
|
|
POST
|
Way to go Ken, that did it. Clearly I need to spend more time with the TOC widget, but I see it now: this is where Nianwei Liu is placing the attributeField name of the attribute to be listed when rendering unique values. I would only caution users that by commenting out the attributeField option, no layers in the TOC will displace a header. Thanks again for your help!
... View more
09-24-2014
10:13 AM
|
0
|
0
|
2376
|
|
POST
|
Hi all- So I'm trying to render groups of values based on the blog at: Data Visualization with ArcGIS API for JavaScript: Show Data by Unique Value | ArcGIS Blog The problem is that while the renderer portion works great, I can't seem to get around the fact that the TOC wants to list the "if else if" statement text within Nianwei Liu's table of contents. Here is some code of what I've done so far, I just can't seem to around the fact that the TOC wants to list the attribute field values on which I am rendering, but is listing the function text instead:
var defSym = new SimpleFillSymbol().setStyle(SimpleFillSymbol.STYLE_SOLID);
defSym.outline.setStyle(SimpleLineSymbol.STYLE_SOLID);
var cszRenderer = new UniqueValueRenderer(defSym, function(graphic) {
if (graphic.attributes['CODE'].indexOf("DTB") !== -1 || graphic.attributes['CODE'].indexOf("DTC") !== -1 ||
graphic.attributes['CODE'].indexOf("DTE") !== -1 || graphic.attributes['CODE'].indexOf("DTN") !== -1){
return "Downtown Overlays";
} else if (graphic.attributes['CODE'].indexOf("G") !== -1 || graphic.attributes['CODE'].indexOf("GU") !== -1){
return "Government Use";
} else {
return "Other Uses";
};
});
var dtSym = new SimpleFillSymbol(SimpleFillSymbol.STYLE_SOLID, new SimpleLineSymbol(SimpleLineSymbol.STYLE_SOLID, new Color("#808000"), 2),new Color("#FF8C00"));
cszRenderer.addValue("Downtown Overlays", dtSym);
var gSym = new SimpleFillSymbol(SimpleFillSymbol.STYLE_SOLID, new SimpleLineSymbol(SimpleLineSymbol.STYLE_SOLID, new Color("#808080"), 2),new Color("#A4F9FE"));
cszRenderer.addValue("Government Use", gSym);
lyrCsZoning.setRenderer(cszRenderer);
Result: Any help is appreciated. If I can just somehow reverse how the renderer is set up so I can return the attribute and not the function. Some sort of nested function I think would work but I just can't see it-- Thanks- David
... View more
09-23-2014
03:16 PM
|
0
|
4
|
3258
|
|
POST
|
Hi Vikram, as you know the label layer must be drawn from the same feature layer that you wish to label. The label layer visibility is controlled by the feature layer visibility. If the feature layer is not visible, then neither is the label layer. If you want to be able to turn the label layer on/off, then you have to set up some kind of control to do so. What we did was to use Nianwei Liu's Table of Contents dijit. Here's some code, hope this helps:
/*create the layer*/
var hghColor = new Color("#004DA8");
var hghLabel = new TextSymbol().setColor(hghColor);
hghLabel.font.setSize("12").setFamily("arial").setWeight(Font.WEIGHT_BOLD);
var hghRenderer = new SimpleRenderer(hghLabel);
var hLabelLayer = new LabelLayer();
hLabelLayer.addFeatureLayer(lyrHighZones, hghRenderer, "{SCHOOL_NAME}", {howManyLabels: "ManyLabels"});
hLabelLayer.id = "HighLabels";
hLabelLayer.minScale = 72223;
hLabelLayer.setVisibility(true);
/*add to toc*/
/* Table Of Contents */
mapMain.on("layers-add-result", function(evt) {
toc = new TOC({
map: mapMain,
layerInfos: [{
layer: hLabelLayer,
title: "High School Labels"
}]
}, "tocDiv");
toc.startup();
/*add the layers*/
mapMain.addLayers([hLabelLayer, lyrHighZones]);
... View more
09-19-2014
01:04 PM
|
0
|
4
|
2698
|
|
POST
|
Yes, that will give you a quick idea on how the data is distributed. Kriging requires that the data be normally distributed or close to normal. For example, rainfall time-series data is a continuous measure but never falls below zero becauce you can't have less than no rainfall right? So in the past I would apply a natural log-tranformation to the data that forces some data values to fall below zero and thus making it pass normalizaiton tests like t and z scores. I could then take say 10 or 15 rainfall stations, log transform the data, then make a surface using kriging. Negative values are then ignored or discarded....
... View more
09-19-2014
12:49 PM
|
0
|
0
|
3328
|
|
POST
|
Hi Daniel, as Dan says the grid structure producing the stair-step will never 'disappear'. It is part of the raster structure. Natural Neighbor, bi-linear, etc will not make a difference. If you are looking into making a smooth surface of any type, I would look into the exact interpolaters such as an IDW or one of the local of global polynomial tools available in the geostatistical analyst tools. Kriging may be appropriate if your data meet normalization criteria. Keep in mind all work on grids, so you will have to export to vector and smooth where (as Dan says) possible and/or appropriate--
... View more
09-11-2014
11:31 AM
|
0
|
2
|
3328
|
|
POST
|
If you are at 10.1 or later you have to overwrite your map service to see changes to layers, such as a color change, label change, or visibility or scale changes
... View more
09-09-2014
09:04 AM
|
0
|
0
|
2106
|
|
POST
|
Hi Daniel, you are going to have to run one of the genearalizaion tools after creating your linework. Once you have an acceptable result your labelling should be fine. As far as your grid cell sizes are concerned, you need to consider things such as your minimum mapping unit and extent.
... View more
09-09-2014
09:00 AM
|
0
|
0
|
3328
|
|
POST
|
Thanks Kelly et al- I ended up borrowing the home_locate.png from arcgis online at http://cdn.arcgis.com/cdn/4922/js/esri/arcgisonline/map/css/images/home_locate.png Then, I just created a simple on load function and added Robert's code:
//on function for home button slider
mapMain.on("load", addHomeSlider);
function addHomeSlider() {
//let's add the home button slider as a created class, requrires dom-Attr
dojo.create("div", {
className: "esriSimpleSliderHomeButton",
title: 'Zoom to Full Extent',
onclick: function () {
if (extentInitial === undefined) {
extentInitial = mapMain.extent;
}
mapMain.setExtent(extentInitial);
}
}, dojo.query(".esriSimpleSliderIncrementButton")[0], "after");
}
Since I'm not utilizing a progress bar for this app, I excluded the code for displaying the status bar message. I then modified the css:
.esriSimpleSliderHomeButton {
border-bottom: 1px solid #666666;
background: url(../css/home_locate.png);
background-repeat: no-repeat;
}
.esriSimpleSliderHomeButton:hover {
background-color: rgb(102, 102, 102);
background-color: rgba(102, 102, 102, 0.9);
}
Which produced this nice clean look:
... View more
09-03-2014
02:38 PM
|
2
|
0
|
3904
|
|
POST
|
Right, thanks Ken. I thought I could pull it out of my downloaded api somewhere, but this will work too. Thanks for the data URI tip...
... View more
09-03-2014
12:52 PM
|
0
|
2
|
3904
|
|
POST
|
Hi Robert- Can you tell me where in the api you are pulling the home slider png?
background-image: url(../images/zoomExtent.png);
... View more
09-03-2014
12:39 PM
|
0
|
4
|
3904
|
|
POST
|
Hi Peter- If you want to apply something like a Fast Fourier Transformation you will probably have to set up and run the appropritate Spatail Analyst Math tools to create an FFT algorithim, a difficult task in ArcGIS but easily performed in ERDAS. In looking at your example though, I don't think you are dealing with an image anamoly, but rather a processsing anaomly created during a merge as you suggest, as such an FFT wouldn't necessarily be appropriate. I would try using the Majority Filter tool (essentially a high-pass filter) first, changing the input paramters for neighbors and definition unitl you produce a reasonable surface.
... View more
09-02-2014
08:02 AM
|
1
|
0
|
1092
|
|
POST
|
Good one Robert, I'd been looking for this one for some time myself- Thank!
... View more
08-26-2014
02:20 PM
|
0
|
0
|
3904
|
|
POST
|
There's something going on with the algorithm. I'm getting the same thing. A very simple case below shows a label layer applied to a half-township section grid. I am also at 3.10 and still get missing labels, regardless of various parameter changes I've applied
... View more
08-25-2014
12:10 PM
|
0
|
0
|
2106
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 3 weeks ago | |
| 1 | 4 weeks ago | |
| 6 | a month ago | |
| 1 | 06-17-2026 06:04 AM | |
| 1 | 06-08-2026 08:37 AM |
| Online Status |
Online
|
| Date Last Visited |
yesterday
|