w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Problem to plot 3D surface with R‏
Try this to see why I don't think this data is well suited for wireframe: cloud(Z~X+Y, data=FI02, xlab="X", ylab="Y", main="Surface elevation", type="l", screen=list(z=-60, x=-60))

Categories : R

kruskal.test shows "All group levels must be finite" error. What is the problem?
It should work if you run data$Grp <- as.factor(data$Grp) Then (as before): kruskal.test(data$Val, data$Grp) This is because Grp is a character not a factor and is.finite applied to an object of character class is always false (see ?is.finite).

Categories : R

How does polyline simplification in Adobe Illustrator work?
I came across the question Smoothing a hand-drawn curve (which this question might actually be a dupe of), which has an answer that proposes using Ramer-Douglas-Peucker and then applying curve fitting according to Philip J. Schneiders approach. A quick adaptation of the provided sample code to my drawing methods results in the following curve: The input data from the question has been reduced to 28 points (which are being drawn using Bezier splines). I'm not sure which approach exactly Adobe is using, but this one serves me extremely well so far. Adaptation So, the code provided by Kris is written for WPF and makes some assumptions in that regard. To work for my case (and because I didn't want to adjust his code), I wrote the following snippet: private List<Point> OptimizeCur

Categories : C#

How to save as SVGZ with external stylesheets in Illustrator
I don't know whether SVGZ will work with CSS but SVGZ is a SVG compressed with GZIP. You can change SVG to SVGZ this way: get SVG file : example.svg remove extension .svg : example compress using GZIP : example.gz change extenson to .svgz : example.svgz

Categories : CSS

Adobe Illustrator CS 6 17.0.0 Pipette gives "wrong" color?
Adobes pipette reads only the RGB values and calculates the CMYK values even if the document is in CMYK - Mode. If you make a small calculation than you can see that CMYK can hold about 10^8 numbers (100 C; * 100 M; * 100 Y; * 100 K;) while RGB can only hold 16,7 * 10^6 (R 256; * G 256; * B 256) which gives a gab of 83*10^6 values. So there is more than one value in CMYK that gives the same RGB value as another CMYK value.

Categories : Pdf

Scripting Adobe Illustrator. How to apply an effect?
Using documents[0].selection[0].reflect.properties in ExtendScript toolkit to find out what properties basic paths have, I don’t see any way to set this effect directly. When I search the JavaScript Reference for Illustrator, the only mention I see of appearance is when it talks about graphic styles. So what I tried was drawing two rectangles, applying the 3D effect to one of them, and saving it as a new graphic style: Then in the script, you can select the other rectangle and then apply the graphic style with documents[0].graphicStyles[6].applyTo(documents[0].selection[0]) Unfortunately, the documentation does say Scripts cannot create new graphic styles. One thing that might be work would be to distribute a document with the script that has all the graphic styles you

Categories : Javascript

How to write a script that does "Save for web" for mutiple resolutions in Adobe Illustrator?
For that i myself use this function function saveDocumentAsPng(d, width, height) { var fileName = d.fullName.toString(); if(fileName.lastIndexOf(".") >= 0) { fileName = fileName.substr(0, fileName.lastIndexOf("."));} fileName += "_wxh.png".replace("w", width).replace("h", height); var exportOptions = new ExportOptionsPNG24(); exportOptions.horizontalScale = exportOptions.verticalScale = 100 * Math.max(width/d.width, height/d.height); var file = new File(fileName); app.activeDocument = d; d.exportFile(file, ExportType.PNG24, exportOptions); } Note that it names a resulting png's with “_[width]x[height]” suffix. I wrote my function based on a sample from adobe's javascript reference http://wwwimages.adobe.com/www.adobe.com/content/dam/Adobe/en/dev

Categories : Misc

Adobe Illustrator expanded objects not generating image map code.
You can try to save it as an SVG. See: http://davidlynch.org/blog/2008/03/creating-an-image-map-from-svg/

Categories : HTML

How can I convert an SVG file to a format read by Cinema 4D as Vector (like Adobe Illustrator ai file)
I use a tool called VectorMagic (http://vectormagic.com/home) it will take any image and convert it to EPS, SVG, PDF, AI, DXF and EMF. Works seamlessly with Illustrator, Corel, and others.

Categories : Misc

How to bring Classic Text From Adobe Illustrator to Adobe Flash Professional?
I must be doing something wrong because the people at Adobe really cannot be that dumb to force developers to do this every time you move graphics from Illustrator to Flash Pro Haha. Good joke. This is the tip of the iceberg when it comes to stupid things that Adobe software does. In my role I do a lot of Flash banners, and the designers use Fireworks. I've done 500+ banners since starting work and almost every single one has needed the text fields to be readjusted once they're imported. The line and letter spacing is never the same, the size doesn't translate correctly, etc. If you don't actually need to the text to be editable, you could consider outlining it before you import it. This way, you'll have the same result when you copy and paste it. This may not be the best solution

Categories : Actionscript

"The gem ... has been deleted. It was installed at" Error. Bundle install doesn't install gems. How to re-install gems?
This solved it for me: "gem install" and "bundle install" do not install gem dependencies after manual gem deletion. How to inform Rubygems that gems were deleted manually? (Delete the .gemspec files for the gems you have removed).

Categories : Misc

How to Install Matplotlib Basemap Module on Windows 7 with WinPython (or any Python stack install)?
I use windows. And my installation failed with official guidance, too. Finally I installed Basemap using the following method. Although I am not sure if it will go right for you, I just offer mine. First of all, you must have pip in your computer. (It is much easier to install, compared with Basemap and other things. And it can be used to install many useful packages.) Then go this great link: http://www.lfd.uci.edu/~gohlke/pythonlibs/ And download the file named "basemap‑1.0.8‑cp27‑none‑win_amd64.whl". Remove the .whl file to directory "C:Python27". (Maybe you installed your python in different disk, then change it accordingly.) Open terminal. (Use cmd or Git Bash or something else.) Use command: pip install basemap‑1.0.8‑cp27‑none‑win_amd64.whl

Categories : Python

Pip install python package into a specific directory other than the default install location
System: Ubuntu 12.04, Enthought Python Distribution (this is where I wanted to install a new python module) So the prefix_path environment variable didn't work for me and pip still kept installing it in the default location. But I used change default directory for pip install question as a guide. And one of the answers helped me achieve what I needed. pip install -d <path_to_my_directory> For the path I used: path_to_epd_directory/lib/python2.7/site-packages This puts the tar.gz file into the site-packages Then extract it using: tar -zxvf pymodule.tar.gz a directory named pymodule is created, cd into that module and type: python setup.py install and that should do the job.

Categories : Python

Error "invalid switch in RUBYOPT: -F (RuntimeError)" is shown while install gems by gem install mechanize
I found the reason. Just because there is a space in the installation path of Ruby RUBY EXECUTABLE: "C:/Program Files/Ruby200-x64/bin/ruby.exe" Re-install the Ruby to the path which doesn't contain space, this error will be fixed. And, of course, AutoRun should be removed from HKCUSoftwareMicrosoftCommand Processor and HKLMSoftwareMicrosoftCommand Processor. That's important!

Categories : Ruby

When exporting .Apk in the android manifest its does not install on other phones, when getting from Bin folder it does install?
There is most likely a problem with the certificate. Try making a new certificate, keystore, and alias, then generate the .apk again. Make sure that no previous instance of the app is on the phone when you try to install this new version or the mismatch of signatures will cause the installation to fail. Also, was there a previous version of the app installed on their phones already? The signature mismatch may occur due to the use of both signed and unsigned(in reality the .apk is singed, but it is done automatically by the system) .apks

Categories : Android

Component install error: JInstaller: :Install: File does not exist
check if you have added this code to your XML: <languages> <language tag="en-GB" client="site">language/en-GB/en-GB.com_helloworld.ini</language> <language tag="en-GB" client="site">language/en-GB/en-GB.com_helloworldt.sys.ini</language> </languages> and: <administration> ... <languages> <language tag="en-GB" client="site">language/en-GB/en-GB.com_helloworld.ini</language> <language tag="en-GB" client="site">language/en-GB/en-GB.com_helloworld.sys.ini</language> </languages> ... </administration> and check if the files are included in your installation ZIP - in right folder, e.g.: language/en-GB/ ... Be aware, the path to the file can be different for

Categories : PHP

C# Install - Change a custom folder location using install dialog
So PATHPROPERTY returns the custom folder location user has selected, If thats the case you have to set that property to "Property" attribute. Also make sure in the User Interface Editor you are getting the user input before installation starts. (You can move up and down the UI to required position)

Categories : C#

How install ruby with rbenv install 1.9.3-p448 ubuntu 12.04 vagrant box?
Download the ruby using your browser from ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p448.tar.bz2 and place it in ~/.rbenv/caches/ruby-1.9.3-p448.tar.bz2, then run rbenv install 1.9.3-p448 Explanation here

Categories : Ruby On Rails

Bundle install gets permission issues with global RVM install
This error doesn't necessarily need to be solved. Your bundle is installing properly, but it's not able to remove cached gems. It's a pretty harmless error unless you're running way short on hard drive space. I actually get this same error too. The problem is that my home directory is remotely mounted, so local root doesn't have permission to modify items there. Local root only has global write permissions on local directories. I imagine, based on what you describe, that you have the same issue. You could remove the files manually, or you could instruct rvm to install gems in a directory on the local machine.

Categories : Ruby On Rails

Install multiple packages on linux (like pip install -r requirements.txt)
Put the list of packages in a text file(say test.txt) with package names separated by spaces, like this - python ruby foo bar then you can just install with apt-get like this - sudo apt-get install $(cat test.txt)

Categories : Linux

Why "bundle install" try to install outdated version of gems?
bundle install or in short bundle does not install the latest gem unless you have left out the version in your Gemfile. e.g. gem 'rails' But usually this is not the case, we specify versions to prevent application from "crashing" when some gems are updated and we unknowingly run bundle update, or for that matter move application to say test or production servers. Usually when adding a gem to Gemfile, we do: gem 'rails', '~> 3.2.7' Note the leading ~> in the version number. This says: use rails gem between versions 3.2.7 and less than 3.3.0. In order for your bundle command to grab rails 4.0, you need to change that line to read either one of the following: gem 'rails', '>= 3.2.7' or gem 'rails', '4.0.0' If you use gem 'rails', '>= 3.2.7' then your rails appl

Categories : Ruby On Rails

rails heroku - how to install javascript dependences that needs 'npm install ...'
If you are deploying a Node app, declare it in your package.json, otherwise, specific it in your gemfile. https://devcenter.heroku.com/articles/getting-started-with-nodejs#declare-dependencies-with-npm

Categories : Ruby On Rails

Trying to install a Scitools Python pkg via 'pip install' but getting error
I had the same error but resolved it by manually installing all the Anaconda packages. NumPy SciPy Pandas PyTables h5py Matplotlib IPython Spyder Qt/PySide VTK Numexpr Astropy Cython LLVM LLVMpy Numba Scikit-learn Scikit-image NLTK NetworkX MayaVi

Categories : Python

Rails : gem install vs. gemfile&bnudle install
RubyGems is akin to a package manager for Ruby. It's a means by which you can install self-contained libraries to use in your applications. When you use gem install gemname you're installing that gem to the current machine that you're developing on. Bundler is a tool for managing the gems that your application depends on. When you create a Gemfile, you list the various gems and their versions that your application requires. This allows you to easily ensure that your application has the gems it needs when you deploy it to a new location - for example, when you push to Heroku, your Gemfile is used to determine all the dependencies of your application. Running bundle install will take the list of required gems in your gemfile and install them if they aren't installed already, just like

Categories : Ruby On Rails

Go install always fails no install directory outside GOPATH
You are using go install on a directory outside the GOPATH folder. Set your GOBIN env variable, or move src folder inside GOPATH. GOPATH/ bin/ src/ go-statsd-client/ More info: GO BUILD Source code, line 296

Categories : Osx

Can't Install gem install mysql2 Ruby WINx64
I've downloaded the connector from http://dev.mysql.com/downloads/mirror.php?id=412857 and typed in the command prompt gem install mysql --platform=ruby -- --with-mysql-include=C:mysql-connector-c-6.1.0-winx64include --with-mysql-lib=C:mysql-connector-c-6.1.0-winx64lib

Categories : Mysql

how to install php 5.4 install on ubuntu desktop 12.04?
Maybe this tutorial will help http://www.barryodonovan.com/index.php/2012/05/22/ubuntu-12-04-precise-pangolin-and-php-5-4-again

Categories : PHP

How can I install Leiningen self-install from behind a firewall?
This should help: https://github.com/technomancy/leiningen/wiki/HTTP-Proxies You should work on your googling skills ;)

Categories : Misc

Steps to Install Git from source, install Post-Git from source, and then load up Posh in PowerShell?
Check out https://github.com/msysgit/msysgit for building Git for Windows. (For what it's worth, I've never built Git on Windows and don't consider myself to have missed out.) Once you have Git built (or installed): Add the location of git.exe to your %PATH% Clone posh-git to a directory of your choosing Run posh-git's install.ps1 to install the default prompt in your $PROFILE

Categories : Windows

Rake db:migrate error Please install the sqlite3 adapter: `gem install activerecord-sqlite3-adapter`
It looks like you might be using sqlite in development. Can you try this in your gemfile instead of what you have? group :development, :test do gem 'sqlite3' gem "unicorn", "~> 4.6.2" end Then usual bundle install and run migration again.

Categories : Ruby On Rails

Python GDAL: pip install --no-install GDAL fails
A workaround to that problem is to Download GDAL Complete from this site Install GDAL Complete.pkg Go to /Library/Frameworks/GDAL.framework/Versions/1.10/ and copy all files in there Go to your virtual environment's sites-packages /venv/lib/python2.7/site-packages and paste the copied files in there

Categories : Python

Permission error when try to install psycopg2 on Mac with "pip install psycopg2"
For a variety of packages that require c compilation (gevent, zeromq, etc.) it seems that pip is adding extra spaces to the command, causing it to fail: go into Xcode and explicitly download the Command Line Tools (under Preferences > Downloads). From: http://www.pressingquestion.com/5111217/Pip-Installation-Adds-Extra-Spaces-To-Command-On-Os-X-108

Categories : Misc

What's the pros and cons to install HBase + Hadoop together vs. install HBase and Hadoop seperately?
Option 1: An integrated cluster. Pros: MapReduce which reads or writes HBase will more efficient as the data locality. Cons: The HBase region server will reduce the performance of the machine (Datanode and TaskTracker) as it need to hold some CPU and memory. The HBase latency may be seconds if there are many MapReduce jobs. So if you want to make HBase response in time, you need more work (For example, using memcache to improve the read performance). Option 2: 2 clusters. Prons: The HBase region server will not impact the performance of the HDFS Datenode and the TaskTracker. Cons: MapReduce needs to read and write the data remotely if it wants to access HBase. The option also needs more machines.

Categories : Hadoop

Please install the postgresql adapter: `gem install activerecord-postgresql-adapter`
First of all best practice is to use same DB for all environments. Could you please run RAILS_ENV=production bundle exec gem install pg on server? The problem seems to be in absence of pg gem in assets group when running RAILS_ENV=production RAILS_GROUPS=assets bundle exec rake assets:precompile

Categories : Ruby On Rails

pip cannot install anything
The explanation is in your logs: Could not fetch URL https://pypi.python.org/simple/yolk/: HTTP Error 503: Service Unavailable Notice the HTTP Error 503: Service Unavailable. It seems the site was down when you were trying to do this. It's good to know that HTTP 5xx errors are server side errors, so you can know the problem was not in your local network but in the remote network. It means try again later ;-) (and cross fingers...) (It works for me now btw.)

Categories : Python

How to install Three.js
if I could offer a friendly suggestion. Three.js is fairly advanced for a first time Javascript programmer, you might want to try some basic tutorials on HTML5 with Javascript, move your way up to library includes and such, then try your hand at Three.js. Here's a couple basic tutorial's on ThreeJS http://aerotwist.com/tutorials/getting-started-with-three-js/ http://stemkoski.github.io/Three.js/#hello-world However, I digress, to include a library in Javascript you use: <script src="relative_path/library_name.js"></script> In your case, download the zip source, copy the build/three.min.js file to a folder relative to your html (like a "js" folder) and use: <script src="js/three.min.js"></script> Kind regards ~D

Categories : Three Js

gem install pg on MAC 10.7.5?
You must have PostgreSQL installed on your before you can install the pg gem. Easiest way to install it is to use homebrew: http://brew.sh/ Make sure you have Xcode installed first. Run: brew install postgresql Add to your GemFile: gem 'pg' Run: bundle install

Categories : Ruby

Why is "install" run twice?
$ bundle install --without production prevents bundler from installing any of the production gems. It also gets saved in your local repository and you don't have to run it more than once. Any subsequent run of bundle install will include --without production. bundle install installs only the missing gems from your Gemfile, while bundle update updates/installs every single gem to the latest version as specified in the GemFile..

Categories : Ruby On Rails

how to install Qt 4.8.4 with exsist Qt 5.1.1
You can install those different two Qt major versions into different paths. You need to make sure when you would like to use the Qt 4 project, you need to have the relevant qmake executable in the path before the other one, or vica versa. If you would not like to change the path dynamically, you can always specify the absolute path to the qmake executable for the one which you would like to use during that session.

Categories : C++

Mac - Can’t install Homebrew
What was the message given when it didn't install correctly the first time? Is the brew binary present in /usr/local/bin ? If so, you probably just need to add it to your path, see: Error Installing Homebrew - Brew Command Not Found

Categories : Osx



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.